﻿<!--
// (c) Copyright Microsoft Corporation.
// This source is subject to the Microsoft Public License (Ms-PL).
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details.
// All other rights reserved.
-->

<ResourceDictionary
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:toolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"
        xmlns:input="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Input"
        xmlns:inputToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Input.Toolkit"
        xmlns:vsm="clr-namespace:System.Windows;assembly=System.Windows"
        xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls"
        xmlns:controlsToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"
        xmlns:controlsPrimitives="clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls"
        xmlns:chartingToolkit="clr-namespace:System.Windows.Controls.DataVisualization.Charting;assembly=System.Windows.Controls.DataVisualization.Toolkit" 
        xmlns:visualizationToolkit="clr-namespace:System.Windows.Controls.DataVisualization;assembly=System.Windows.Controls.DataVisualization.Toolkit"
        xmlns:chartingPrimitivesToolkit="clr-namespace:System.Windows.Controls.DataVisualization.Charting.Primitives;assembly=System.Windows.Controls.DataVisualization.Toolkit"
        xmlns:data="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data"
        xmlns:dataPrimitives="clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls.Data" 
        xmlns:dataForm="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data.DataForm.Toolkit"
        xmlns:inputPrimitivesToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Input"
        xmlns:inputToolkitPrimitives="clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls.Input.Toolkit"
        xmlns:system="clr-namespace:System;assembly=mscorlib" 
        xmlns:layoutPrimitivesToolkit="clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls.Layout.Toolkit"
        xmlns:layoutToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Layout.Toolkit"
        xmlns:theming="clr-namespace:System.Windows.Controls.Theming;assembly=System.Windows.Controls.Theming.Toolkit"
        xmlns:dataInput="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data.Input"
        xmlns:themingToolkit="clr-namespace:System.Windows.Controls.Theming;assembly=System.Windows.Controls.Theming.Toolkit"
        xmlns:bureauBlue="clr-namespace:System.Windows.Controls.Theming;assembly=System.Windows.Controls.Theming.BureauBlue">

    <!-- Theme -->
    <LinearGradientBrush x:Key="ThemeBackgroundBrush" StartPoint="0.5,1" EndPoint="0.5,0">
        <GradientStop Color="#FFBFDBFF" Offset="0" />
        <GradientStop Color="#FFA6C2E5" Offset="1" />
    </LinearGradientBrush>
    <SolidColorBrush x:Key="ThemeForegroundBrush" Color="Black" />
    <Style TargetType="themingToolkit:Theme">
        <Setter Property="Background" Value="{StaticResource ThemeBackgroundBrush}" />
        <Setter Property="Foreground" Value="{StaticResource ThemeForegroundBrush}" />
    </Style>
    <Style TargetType="bureauBlue:BureauBlueTheme">
        <Setter Property="Background" Value="{StaticResource ThemeBackgroundBrush}" />
        <Setter Property="Foreground" Value="{StaticResource ThemeForegroundBrush}" />
    </Style>

    <!--ValidationTooltipTemplate-->
    <ControlTemplate x:Key="ValidationToolTipTemplate">
        <Grid x:Name="Root" Margin="5,0" Opacity="0" RenderTransformOrigin="0,0">
            <vsm:VisualStateManager.VisualStateGroups>
                <vsm:VisualStateGroup x:Name="OpenStates">
                    <vsm:VisualStateGroup.Transitions>
                        <vsm:VisualTransition GeneratedDuration="0"/>
                        <vsm:VisualTransition GeneratedDuration="0:0:0.2" To="Open">
                            <Storyboard>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="xform" Storyboard.TargetProperty="X">
                                    <SplineDoubleKeyFrame KeyTime="0:0:0.2" Value="0"/>
                                </DoubleAnimationUsingKeyFrames>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity">
                                    <SplineDoubleKeyFrame KeyTime="0:0:0.2" Value="1"/>
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </vsm:VisualTransition>
                    </vsm:VisualStateGroup.Transitions>
                    <vsm:VisualState x:Name="Closed">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity">
                                <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                    <vsm:VisualState x:Name="Open">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="xform" Storyboard.TargetProperty="X">
                                <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                            </DoubleAnimationUsingKeyFrames>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity">
                                <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                </vsm:VisualStateGroup>
            </vsm:VisualStateManager.VisualStateGroups>
            <Grid.RenderTransform>
                <TranslateTransform x:Name="xform" X="-25"/>
            </Grid.RenderTransform>
            <Border Margin="4,4,-4,-4" Background="#152A2E31" CornerRadius="4"/>
            <Border Margin="3,3,-3,-3" Background="#252A2E31" CornerRadius="4"/>
            <Border Margin="2,2,-2,-2" Background="#352A2E31" CornerRadius="4"/>
            <Border Margin="1,1,-1,-1" Background="#452A2E31" CornerRadius="4"/>
            <Border Background="#FFDC000C" CornerRadius="4"/>
            <Border CornerRadius="4">
                <Border.Background>
                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                        <GradientStop Color="#66FFFFFF"/>
                        <GradientStop Color="#66000000" Offset="1"/>
                        <GradientStop Color="#00E5E5E5" Offset="0.1"/>
                        <GradientStop Color="#00161616" Offset="0.9"/>
                    </LinearGradientBrush>
                </Border.Background>
                <TextBlock Margin="8,3,8,4" MaxWidth="250" UseLayoutRounding="false" Foreground="White" Text="{Binding Path=(Validation.Errors)[0].ErrorContent}" TextWrapping="Wrap"/>
            </Border>
        </Grid>
    </ControlTemplate>
    
    <!-- Static Resources -->
    <SolidColorBrush x:Key="TextColor" Color="#FF000000"/>
    <SolidColorBrush x:Key="HeaderSeparator" Color="#FF96BBFD" />
    <SolidColorBrush x:Key="GridBorder" Color="#FF6593CF" />
    <SolidColorBrush x:Key="ControlBorderBrush" Color="#FFB1703C"/>

    <LinearGradientBrush x:Key="ControlBackgroundBrush" EndPoint="1.204,0.5" StartPoint="0.056,0.5">
        <GradientStop Color="#FFBFDBFF" Offset="0"/>
        <GradientStop Color="#FFA6C2E5" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ColumnHeaderBackground" EndPoint="0.7,1" StartPoint="0.7,0">
        <GradientStop Color="#FFFFFFFF" Offset="0"/>
        <GradientStop Color="#FFC7DFFF" Offset="0.478"/>
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="RowHeaderBackground" EndPoint="0.006,0.495" StartPoint="0.984,0.5">
        <GradientStop Color="#FFBDD8FE"/>
        <GradientStop Color="#FFFFFFFF" Offset="1"/>
    </LinearGradientBrush>
    <Style TargetType="ToolTip">
        <Setter Property="Background" Value="#33000000"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Padding" Value="3,0,3,0"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ToolTip">
                    <Border x:Name="Root" Background="{TemplateBinding Background}" BorderBrush="#19000000" CornerRadius="3">
                        <Border Margin="-3,-3,3,3" BorderBrush="#FF767676" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3" Padding="4">
                            <Border.Resources>
                                <Storyboard x:Key="Visible State"/>
                                <Storyboard x:Key="Normal State"/>
                            </Border.Resources>
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.004"/>
                                    <GradientStop Color="#FFCDDCF0" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <ContentPresenter
	                                Content="{TemplateBinding Content}"
	                                ContentTemplate="{TemplateBinding ContentTemplate}"
	                                Cursor="{TemplateBinding Cursor}"
	                                Margin="{TemplateBinding Padding}" />
                        </Border>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ScrollBar">
        <Setter Property="MinWidth" Value="17"/>
        <Setter Property="MinHeight" Value="17"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ScrollBar">
                    <Grid x:Name="Root">
                        <Grid.Resources>

                            <!-- RepeatButton Templates -->
                            <ControlTemplate x:Key="RepeatButtonTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root" Background="Transparent">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualState x:Name="Normal" />
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                </Grid>
                            </ControlTemplate>

                            <!-- Horizontal Inc/Dec Templates -->
                            <ControlTemplate x:Key="HorizontalIncrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver"/>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="Press" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledElement" Storyboard.TargetProperty="Opacity" To=".7" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="Background" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF8C97A5">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.64,0.5" StartPoint="0.36,0.5">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFC7D9F1" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="Press" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF19598A" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.64,0.5" StartPoint="0.36,0.5">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFD1D6DD" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="Highlight" Margin="1" RadiusX="0.5" RadiusY="0.5" Stroke="#99FFFFFF" StrokeThickness="1" Opacity="0.9" IsHitTestVisible="false"/>
                                    <Rectangle x:Name="DisabledElement" RadiusX="0" RadiusY="0" Fill="#FFFFFFFF" Opacity="0"/>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="HorizontalDecrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver"/>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledElement" Storyboard.TargetProperty="Opacity" To=".7" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="Background" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF8C97A5">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.36,0.5" StartPoint="0.64,0.5">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFC7D9F1" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="BackgroundPressed" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF19598A" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.36,0.5" StartPoint="0.64,0.5">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFD1D6DD" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="Highlight" Margin="1" RadiusX="0.5" RadiusY="0.5" Stroke="#FFFFFFFF" StrokeThickness="1"  Opacity="0.9" IsHitTestVisible="false"/>
                                    <Rectangle x:Name="DisabledElement" RadiusX="0" RadiusY="0" Fill="#FFFFFFFF" Opacity="0"/>
                                </Grid>
                            </ControlTemplate>

                            <!-- Vertical Inc/Dec Templates -->
                            <ControlTemplate x:Key="VerticalIncrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver"/>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="1" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledElement" Storyboard.TargetProperty="Opacity" To=".7" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="Background" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF8C97A5">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                <GradientStop Color="#FFC7D9F1" Offset="0.5"/>
                                                <GradientStop Color="#FFF1F6FE" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="BackgroundPressed" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF19598A" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                <GradientStop Color="#FFD1D6DD" Offset="0.5"/>
                                                <GradientStop Color="#FFF1F6FE" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="Highlight" Margin="1" RadiusX="0.5" RadiusY="0.5" Stroke="#99FFFFFF" StrokeThickness="1" Opacity="0.9" IsHitTestVisible="false"/>
                                    <Rectangle x:Name="DisabledElement" RadiusX="0" RadiusY="0" Fill="#FFFFFFFF" Opacity="0"/>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="VerticalDecrementTemplate" TargetType="RepeatButton">
                                <Grid x:Name="Root">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver"/>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledElement" Storyboard.TargetProperty="Opacity" To=".7" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="Background" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF8C97A5">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFC7D9F1" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="BackgroundPressed" RadiusX="0.5" RadiusY="0.5" StrokeThickness="1" Stroke="#FF19598A" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                <GradientStop Color="#FFF1F6FE" Offset="0.5"/>
                                                <GradientStop Color="#FFD1D6DD" Offset="0.513"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="Highlight" Margin="1" RadiusX="0.5" RadiusY="0.5" Stroke="#99FFFFFF" StrokeThickness="1" Opacity="0.9" IsHitTestVisible="false"/>
                                    <Rectangle x:Name="DisabledElement" RadiusX="0" RadiusY="0" Fill="#FFFFFFFF" Opacity="0"/>
                                </Grid>
                            </ControlTemplate>

                            <!-- Thumb Templates -->
                            <ControlTemplate x:Key="VerticalThumbTemplate" TargetType="Thumb">
                                <Grid>
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundMouseOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="ThumbVisual" Storyboard.TargetProperty="Opacity" To="0" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid x:Name="ThumbVisual">
                                        <Rectangle x:Name="Background" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF606F94">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFD1DBE6" Offset="0"/>
                                                    <GradientStop Color="#FFD1DAE4" Offset="0.5"/>
                                                    <GradientStop Color="#FFE6E9F0" Offset="0.513"/>
                                                    <GradientStop Color="#FFE8E9E9" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="BackgroundMouseOver" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF3C6EB0" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFB4D1F7" Offset="0"/>
                                                    <GradientStop Color="#FFAACBF6" Offset="0.5"/>
                                                    <GradientStop Color="#FFCADFFA" Offset="0.513"/>
                                                    <GradientStop Color="#FFBED0E8" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="BackgroundPressed" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF17498A" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFB4D1F7" Offset="0"/>
                                                    <GradientStop Color="#FF6EA6F0" Offset="0.5"/>
                                                    <GradientStop Color="#FFA4C7F6" Offset="0.513"/>
                                                    <GradientStop Color="#FF9CBBE5" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path Margin="0,-6,0,0" Width="11" Height="1" Stretch="Fill" Stroke="#FF848485" StrokeThickness="1" Data="M4.8333325,7.2499995 L12.012101,7.2499995" VerticalAlignment="Center" HorizontalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.487"/>
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="0,-2,0,0" Width="11" Height="1" Stretch="Fill" Stroke="#FF848485" StrokeThickness="1" Data="M4.8333325,7.2499995 L12.012101,7.2499995" VerticalAlignment="Center" HorizontalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.487"/>
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="0,0,0,-2" Width="11" Height="1" Stretch="Fill" Stroke="#FF848485" StrokeThickness="1" Data="M4.8333325,7.2499995 L12.012101,7.2499995" VerticalAlignment="Center" HorizontalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.487"/>
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="0,0,0,-6" Width="11" Height="1" Stretch="Fill" Stroke="#FF848485" StrokeThickness="1" Data="M4.8333325,7.2499995 L12.012101,7.2499995" VerticalAlignment="Center" HorizontalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="-0.062,0.5" StartPoint="1.062,0.5">
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.487"/>
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Rectangle x:Name="Highlight" Margin="1" RadiusX="0.5" RadiusY="0.5" Stroke="#FFFFFFFF" StrokeThickness="1" Opacity="0.6" IsHitTestVisible="false" />
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="HorizontalThumbTemplate" TargetType="Thumb">
                                <Grid>
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition To="MouseOver" GeneratedDuration="0:0:0.1" />
                                                <vsm:VisualTransition To="Pressed" GeneratedDuration="0:0:0.1" />
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal" />
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="ThumbVisual" Storyboard.TargetProperty="Opacity" To="0" />
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid x:Name="ThumbVisual" Grid.RowSpan="2">
                                        <Rectangle x:Name="Background" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF606F94">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFE8E9E9" Offset="0"/>
                                                    <GradientStop Color="#FFE6E9F0" Offset="0.5"/>
                                                    <GradientStop Color="#FFD1DAE4" Offset="0.513"/>
                                                    <GradientStop Color="#FFD1DBE6" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="BackgroundOver" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF3C6EB0" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFBED0E8" Offset="0"/>
                                                    <GradientStop Color="#FFCADFFA" Offset="0.5"/>
                                                    <GradientStop Color="#FFAACBF6" Offset="0.513"/>
                                                    <GradientStop Color="#FFB4D1F7" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="BackgroundPressed" RadiusX="1.5" RadiusY="1.5" StrokeThickness="1" Stroke="#FF17498A" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FF9CBBE5" Offset="0"/>
                                                    <GradientStop Color="#FFA4C7F6" Offset="0.5"/>
                                                    <GradientStop Color="#FF6EA6F0" Offset="0.513"/>
                                                    <GradientStop Color="#FFB4D1F7" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path Margin="-6,0,0,0" Width="1" Height="11" Stretch="Fill" Stroke="#FF808082" StrokeThickness="1" Data="M6.8333325,4.916666 L6.8333325,11.504745" HorizontalAlignment="Center" VerticalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.487"/>
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="-2,0,0,0" Width="1" Height="11" Stretch="Fill" Stroke="#FF808082" StrokeThickness="1" Data="M6.8333325,4.916666 L6.8333325,11.504745" HorizontalAlignment="Center" VerticalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.487"/>
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="0,0,-2,0" Width="1" Height="11" Stretch="Fill" Stroke="#FF808082" StrokeThickness="1" Data="M6.8333325,4.916666 L6.8333325,11.504745" HorizontalAlignment="Center" VerticalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.487"/>
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Path Margin="0,0,-6,0" Width="1" Height="11" Stretch="Fill" Stroke="#FF808082" StrokeThickness="1" Data="M6.8333325,4.916666 L6.8333325,11.504745" HorizontalAlignment="Center" VerticalAlignment="Center">
                                            <Path.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFF0F0F0" Offset="0.487"/>
                                                    <GradientStop Color="#FFC8C9CC" Offset="0.518"/>
                                                </LinearGradientBrush>
                                            </Path.Fill>
                                        </Path>
                                        <Rectangle x:Name="Highlight" RadiusX="0.5" RadiusY="0.5" Stroke="#FFFFFFFF" StrokeThickness="1" Margin="1" Opacity="0.6" IsHitTestVisible="false"/>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                        </Grid.Resources>

                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver" >
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="HorizontalSmallDecrease" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="HorizontalSmallIncrease" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="VerticalSmallDecrease" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="VerticalSmallIncrease" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity" To="0.5" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>

                        <!-- Horizontal Template -->
                        <Grid x:Name="HorizontalRoot">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="Auto" />
                            </Grid.ColumnDefinitions>

                            <!-- Track Layer -->
                            <Rectangle Grid.ColumnSpan="5" RadiusX="0" RadiusY="0" StrokeThickness="1" Stroke="#FFF0F0F0" Fill="#FFEFEFEF"/>

                            <!-- Repeat Buttons + Thumb -->
                            <RepeatButton x:Name="HorizontalSmallDecrease" Grid.Column="0" Width="18" Opacity="0" Interval="50" IsTabStop="False" Template="{StaticResource HorizontalDecrementTemplate}" />
                            <RepeatButton x:Name="HorizontalLargeDecrease" Grid.Column="1" Width="0" Interval="50" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" />
                            <Thumb x:Name="HorizontalThumb" Grid.Column="2" MinWidth="18" Width="18" Template="{StaticResource HorizontalThumbTemplate}" />
                            <RepeatButton x:Name="HorizontalLargeIncrease" Grid.Column="3" Interval="50" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" />
                            <RepeatButton x:Name="HorizontalSmallIncrease" Grid.Column="4" Width="18" Opacity="0" Interval="50" IsTabStop="False" Template="{StaticResource HorizontalIncrementTemplate}" />
                            <Path Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z " Grid.Column="0" Height="10" Width="6" HorizontalAlignment="Center" VerticalAlignment="Center" Stretch="Uniform" IsHitTestVisible="False">
                                <Path.Fill>
                                    <LinearGradientBrush EndPoint="1.471,0.5" StartPoint="0.138,0.525">
                                        <GradientStop Color="#FF2B3B60"/>
                                        <GradientStop Color="#FF5E6D91" Offset="1"/>
                                    </LinearGradientBrush>
                                </Path.Fill>
                            </Path>
                            <Path Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z " Grid.Column="4" Height="10" Width="6" HorizontalAlignment="Center" VerticalAlignment="Center" Stretch="Uniform" IsHitTestVisible="False">
                                <Path.Fill>
                                    <LinearGradientBrush EndPoint="-0.237,0.525" StartPoint="0.679,0.525">
                                        <GradientStop Color="#FF2B3B60"/>
                                        <GradientStop Color="#FF5E6D91" Offset="0.991"/>
                                    </LinearGradientBrush>
                                </Path.Fill>
                            </Path>
                        </Grid>

                        <!-- Vertical Template -->
                        <Grid x:Name="VerticalRoot" Visibility="Collapsed">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*" />
                                <RowDefinition Height="Auto" />
                            </Grid.RowDefinitions>

                            <!-- Track Layer -->
                            <Rectangle Grid.RowSpan="5" RadiusX="0" RadiusY="0" StrokeThickness="1" Stroke="#FFF0F0F0" Fill="#FFEFEFEF"/>

                            <!-- Repeat Buttons + Thumb -->
                            <RepeatButton x:Name="VerticalSmallDecrease" Grid.Row="0" Height="18" Opacity="0" Interval="50" IsTabStop="False" Template="{StaticResource VerticalDecrementTemplate}" />
                            <RepeatButton x:Name="VerticalLargeDecrease" Grid.Row="1" Height="0" Interval="50" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" />
                            <Thumb x:Name="VerticalThumb" Grid.Row="2" MinHeight="18" Height="18" Template="{StaticResource VerticalThumbTemplate}" />
                            <RepeatButton x:Name="VerticalLargeIncrease" Grid.Row="3" Interval="50" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}" />
                            <RepeatButton x:Name="VerticalSmallIncrease" Grid.Row="4" Height="18" Opacity="0" Interval="50" IsTabStop="False" Template="{StaticResource VerticalIncrementTemplate}" />

                            <Path Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " Height="6" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center" Stretch="Uniform" IsHitTestVisible="False">
                                <Path.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FF5E6D91"/>
                                        <GradientStop Color="#FF2B3B60" Offset="1"/>
                                    </LinearGradientBrush>
                                </Path.Fill>
                            </Path>
                            <Path Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " Grid.Row="4" Height="6" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center" Stretch="Uniform" IsHitTestVisible="False">
                                <Path.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FF5E6D91" Offset="0.004"/>
                                        <GradientStop Color="#FF2B3B60" Offset="0.996"/>
                                    </LinearGradientBrush>
                                </Path.Fill>
                            </Path>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ScrollViewer">
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalScrollBarVisibility" Value="Visible" />
        <Setter Property="Padding" Value="0"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush" Value="#FFA4A4A4"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ScrollViewer">
                    <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1">
                        <Grid Background="{TemplateBinding Background}">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="*"/>
                                <RowDefinition Height="Auto"/>
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*"/>
                                <ColumnDefinition Width="Auto"/>
                            </Grid.ColumnDefinitions>

                            <ScrollContentPresenter x:Name="ScrollContentPresenter"
                                           Cursor="{TemplateBinding Cursor}"
                                           Margin="{TemplateBinding Padding}"
                                           ContentTemplate="{TemplateBinding ContentTemplate}"/>

                            <ScrollBar x:Name="VerticalScrollBar" Width="16"
	                                       IsTabStop="False"
	                                       Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}"
	                                       Grid.Column="1" Grid.Row="0" Orientation="Vertical"
	                                       ViewportSize="{TemplateBinding ViewportHeight}"
										  
	                                       Maximum="{TemplateBinding ScrollableHeight}"
	                                       Minimum="0"
	                                       Value="{TemplateBinding VerticalOffset}"
	                                       IsEnabled="True"/>

                            <ScrollBar x:Name="HorizontalScrollBar" Height="16"
	                                       IsTabStop="False"
	                                       Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}"
	                                       Grid.Column="0" Grid.Row="1" Orientation="Horizontal"
	                                       ViewportSize="{TemplateBinding ViewportWidth}"
										  
	                                       Maximum="{TemplateBinding ScrollableWidth}"
	                                       Minimum="0"
	                                       Value="{TemplateBinding HorizontalOffset}"/>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ComboBoxItem">
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Padding" Value="3" />
        <Setter Property="TabNavigation" Value="Local" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ComboBoxItem">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundGradientOver" Storyboard.TargetProperty="Opacity" To="0.73"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates">
                                <vsm:VisualState x:Name="Unselected" />
                                <vsm:VisualState x:Name="Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundGradientSelected" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused"/>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="BackgroundGradientOver" RadiusX="1" RadiusY="1" Stroke="#FFDBCE99" Opacity="0">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#F9FEF3B5" Offset="0.318"/>
                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                    <GradientStop Color="#FFFFF48B" Offset="0.995"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                        </Rectangle>
                        <Rectangle x:Name="BackgroundGradientSelected" StrokeThickness="1" RadiusX="1" RadiusY="1" Opacity="0">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF636363" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                            <Rectangle.Stroke>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#C8856B57" Offset="0"/>
                                    <GradientStop Color="#FFFDAD11" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Stroke>
                        </Rectangle>
                        <ContentPresenter
	                        	x:Name="contentPresenter"
	                        	Content="{TemplateBinding Content}"
	                        	ContentTemplate="{TemplateBinding ContentTemplate}"
	                        	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                        	Margin="{TemplateBinding Padding}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ListBoxItem">
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Padding" Value="3" />
        <Setter Property="TabNavigation" Value="Local" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListBoxItem">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" >
                                    <Storyboard/>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundGradientOver" Storyboard.TargetProperty="Opacity" To="0.73"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="BackgroundGradientSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates">
                                <vsm:VisualState x:Name="Unselected" />
                                <vsm:VisualState x:Name="Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundGradientSelected" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundGradientSelectedDisabled" Storyboard.TargetProperty="Opacity" To="0.55"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused"/>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="BackgroundGradientOver" RadiusX="1" RadiusY="1" Stroke="#FFDBCE99" Opacity="0">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#F9FEF3B5" Offset="0.318"/>
                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                    <GradientStop Color="#FFFFF48B" Offset="0.995"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                        </Rectangle>
                        <Rectangle x:Name="BackgroundGradientSelectedDisabled" RadiusX="1" RadiusY="1" Opacity="0">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.046"/>
                                    <GradientStop Color="#FFD7E0EA" Offset="0.194"/>
                                    <GradientStop Color="#FFBCC5D5" Offset="0.507"/>
                                    <GradientStop Color="#FFA4ADBB" Offset="0.521"/>
                                    <GradientStop Color="#FFBAC1CF" Offset="0.811"/>
                                    <GradientStop Color="#FFE3E4E6" Offset="0.982"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                            <Rectangle.Stroke>
                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                    <GradientStop Color="#FF8B8B8B"/>
                                    <GradientStop Color="#FFADADAD" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Stroke>
                        </Rectangle>
                        <Rectangle x:Name="BackgroundGradientSelected" StrokeThickness="1" RadiusX="1" RadiusY="1" Opacity="0">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF636363" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                            <Rectangle.Stroke>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#C8856B57" Offset="0"/>
                                    <GradientStop Color="#FFFDAD11" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Stroke>
                        </Rectangle>
                        <ContentPresenter
	                        	x:Name="contentPresenter"
	                        	Content="{TemplateBinding Content}"
	                        	ContentTemplate="{TemplateBinding ContentTemplate}"
	                        	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                        	Margin="{TemplateBinding Padding}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ListBox">
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Padding" Value="0"/>
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="TabNavigation" Value="Once" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListBox">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border Background="{StaticResource ControlBackgroundBrush}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1">
                            <ScrollViewer x:Name="ScrollViewer" Foreground="{TemplateBinding Foreground}" BorderThickness="0" Padding="{TemplateBinding Padding}">
                                <ItemsPresenter />
                            </ScrollViewer>
                        </Border>
                        <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                    <ToolTip.Triggers>
                                        <EventTrigger RoutedEvent="Canvas.Loaded">
                                            <BeginStoryboard>
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                        <DiscreteObjectKeyFrame KeyTime="0">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <system:Boolean>true</system:Boolean>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </BeginStoryboard>
                                        </EventTrigger>
                                    </ToolTip.Triggers>
                                </ToolTip>
                            </ToolTipService.ToolTip>
                            <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                            </Grid>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ComboBox">
        <Setter Property="HorizontalContentAlignment" Value="Stretch" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Padding" Value="6,2,25,2" />
        <Setter Property="TabNavigation" Value="Once" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ComboBox">
                    <Grid>
                        <Grid.Resources>
                            <Style x:Name="comboToggleStyle" TargetType="ToggleButton">
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="ToggleButton">
                                            <Grid>
                                                <vsm:VisualStateManager.VisualStateGroups>
                                                    <vsm:VisualStateGroup x:Name="CommonStates">
                                                        <vsm:VisualStateGroup.Transitions>
                                                            <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                            <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                                        </vsm:VisualStateGroup.Transitions>
                                                        <vsm:VisualState x:Name="Normal"/>
                                                        <vsm:VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="rectangleOver" Storyboard.TargetProperty="Opacity" To="0.8"/>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" To="#FFFFFFFF"/>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="rectanglePress" Storyboard.TargetProperty="Opacity" To="0.8"/>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" To="#FFFFFFFF"/>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                    </vsm:VisualStateGroup>
                                                    <vsm:VisualStateGroup x:Name="CheckStates">
                                                        <vsm:VisualState x:Name="Checked">
                                                            <Storyboard>
                                                                <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="BackgroundChecked" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="Unchecked"/>
                                                    </vsm:VisualStateGroup>
                                                    <vsm:VisualStateGroup x:Name="FocusStates">
                                                        <vsm:VisualState x:Name="Focused"/>
                                                        <vsm:VisualState x:Name="Unfocused"/>
                                                    </vsm:VisualStateGroup>
                                                </vsm:VisualStateManager.VisualStateGroups>
                                                <Rectangle x:Name="Background" Fill="#FFEAF2FB" Stroke="#FF9EBBDE" IsHitTestVisible="false" />
                                                <Rectangle x:Name="BackgroundChecked" Margin="1" Fill="#FFFFFFFF" IsHitTestVisible="false" Visibility="Collapsed" />
                                                <Rectangle x:Name="rectangleOver" Width="15" Stroke="#FFE8E8E8" HorizontalAlignment="Right" Opacity="0">
                                                    <Rectangle.Fill>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                            <GradientStop Color="#FFFEDE8A" Offset="0.498"/>
                                                            <GradientStop Color="#FFFFCE23" Offset="0.507"/>
                                                            <GradientStop Color="#FFFCE580" Offset="0.949"/>
                                                            <GradientStop Color="#FFFEE8AF" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Rectangle.Fill>
                                                </Rectangle>
                                                <Rectangle x:Name="rectanglePress" Width="15" Stroke="#FC9E9D9B" HorizontalAlignment="Right" Opacity="0">
                                                    <Rectangle.Fill>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#F4CBBBAB" Offset="0"/>
                                                            <GradientStop Color="#FFFCBF78" Offset="0.442"/>
                                                            <GradientStop Color="#FFFD8D2C" Offset="0.452"/>
                                                            <GradientStop Color="#FFFCA84B" Offset="0.802"/>
                                                            <GradientStop Color="#FFFCE38F" Offset="0.977"/>
                                                        </LinearGradientBrush>
                                                    </Rectangle.Fill>
                                                </Rectangle>
                                                <Rectangle x:Name="DisabledVisualElement" Margin="1" Fill="#00FFFFFF" IsHitTestVisible="false" Visibility="Collapsed" />
                                                <Path x:Name="BtnArrow" Margin="0,0,4,0" Width="6" Fill="#FF527DB5" Stretch="Uniform" HorizontalAlignment="Right" Data="F1 M 301.14,-189.041L 311.57,-189.041L 306.355,-182.942L 301.14,-189.041 Z "/>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                                <vsm:VisualState x:Name="FocusedDropDown"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>

                        </vsm:VisualStateManager.VisualStateGroups>
                        <Popup x:Name="Popup" Margin="0,1,0,0">
                            <Border x:Name="PopupBorder" Margin="0,-1,0,0" BorderBrush="#FFB1703C" BorderThickness="1" CornerRadius="0,0,3,3">
                                <Border.Background>
                                    <LinearGradientBrush EndPoint="1,1" StartPoint="0,1">
                                        <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                        <GradientStop Color="#FFD4D7DB" Offset="1"/>
                                    </LinearGradientBrush>
                                </Border.Background>
                                <ScrollViewer x:Name="ScrollViewer" Padding="1" BorderThickness="0">
                                    <ItemsPresenter/>
                                </ScrollViewer>
                            </Border>
                        </Popup>
                        <Border x:Name="ContentPresenterBorder">
                            <Grid Height="22">
                                <ToggleButton x:Name="DropDownToggle" Style="{StaticResource comboToggleStyle}"/>
                                <ContentPresenter x:Name="ContentPresenter" 
	                    				Margin="{TemplateBinding Padding}"  
	                    				HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
										VerticalAlignment="Center">
                                    <TextBlock Text=" "/>
                                </ContentPresenter>
                                <Rectangle x:Name="DisabledVisualElement" Fill="#A5FFFFFF" Stroke="#0CFFFFFF" RadiusX="0" RadiusY="0" IsHitTestVisible="false" Visibility="Collapsed" />
                                <Rectangle x:Name="FocusVisualElement" Margin="-1" Stroke="#FFF28926" StrokeThickness="1" IsHitTestVisible="false" Visibility="Collapsed" />
                            </Grid>
                        </Border>
                        <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                    <ToolTip.Triggers>
                                        <EventTrigger RoutedEvent="Canvas.Loaded">
                                            <BeginStoryboard>
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                        <DiscreteObjectKeyFrame KeyTime="0">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <system:Boolean>true</system:Boolean>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </BeginStoryboard>
                                        </EventTrigger>
                                    </ToolTip.Triggers>
                                </ToolTip>
                            </ToolTipService.ToolTip>
                            <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                            </Grid>
                        </Border>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="dataPrimitives:DataGridColumnHeader">
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="FontWeight" Value="Bold"/>
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="SeparatorBrush" Value="{StaticResource HeaderSeparator}"/>
        <Setter Property="SeparatorVisibility" Value="Visible"/>
        <Setter Property="Padding" Value="4,6,5,6"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="dataPrimitives:DataGridColumnHeader">
                    <Grid x:Name="Root">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="Auto"/>
                        </Grid.ColumnDefinitions>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:0.1"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SortStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:0.1"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Unsorted"/>
                                <vsm:VisualState x:Name="SortAscending">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SortIcon" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="SortDescending">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SortIcon" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SortIcon" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" To="-1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SortIcon" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" To="3"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="BackgroundGradient" Grid.ColumnSpan="3" Stretch="Fill" Fill="{StaticResource ColumnHeaderBackground}"/>
                        <ContentPresenter Margin="{TemplateBinding Padding}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Content}" Cursor="{TemplateBinding Cursor}"/>
                        <Path x:Name="SortIcon" Margin="0,-3,1,0" Grid.Column="1" Height="6" Width="10" Fill="#FF7CA9FD" HorizontalAlignment="Right" Stretch="Uniform" Opacity="0" Data="F1 M -5.215,6.099L 5.215,6.099L 0,0L -5.215,6.099 Z " RenderTransformOrigin="0.5,0.5">
                            <Path.RenderTransform>
                                <TransformGroup>
                                    <ScaleTransform/>
                                    <SkewTransform/>
                                    <RotateTransform/>
                                    <TranslateTransform/>
                                </TransformGroup>
                            </Path.RenderTransform>
                        </Path>
                        <Rectangle x:Name="VerticalSeparator" Margin="0,3,0,3" Grid.Column="2" Width="1" Fill="{TemplateBinding SeparatorBrush}" Visibility="{TemplateBinding SeparatorVisibility}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="data:DataGridCell">
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="Cursor" Value="Arrow"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="data:DataGridCell">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CurrentStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Regular"/>
                                <vsm:VisualState x:Name="Current">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="FocusVisual" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="Auto"/>
                        </Grid.ColumnDefinitions>
                        <Rectangle x:Name="FocusVisual" Margin="0,1,0,1" Fill="#FFFFFFFF" Opacity="0" IsHitTestVisible="false"/>
                        <ContentPresenter Margin="{TemplateBinding Padding}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" Cursor="{TemplateBinding Cursor}"/>
                        <Rectangle x:Name="RightGridLine" Grid.Column="1" Width="1"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="dataPrimitives:DataGridRowHeader">
        <Setter Property="SeparatorBrush" Value="{StaticResource HeaderSeparator}"/>
        <Setter Property="SeparatorVisibility" Value="Visible"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="dataPrimitives:DataGridRowHeader">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOverSelected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="MouseOver CurrentRow Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentRowGlyph" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOverSelected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Normal CurrentRow">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentRowGlyph" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOverSelected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Normal Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentRowGlyph" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOverSelected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Normal EditingRow">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentRowGlyph" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOverSelected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <Rectangle x:Name="Background" Grid.ColumnSpan="2" Grid.RowSpan="2" Stretch="Fill" Fill="{StaticResource RowHeaderBackground}"/>
                        <Rectangle x:Name="BackgroundOverSelected" Grid.ColumnSpan="2" Stretch="Fill" Opacity="0" Fill="{StaticResource RowHeaderBackground}" RenderTransformOrigin="0.5,0.5">
                            <Rectangle.RenderTransform>
                                <TransformGroup>
                                    <ScaleTransform ScaleX="-1"/>
                                </TransformGroup>
                            </Rectangle.RenderTransform>
                        </Rectangle>
                        <Rectangle x:Name="HorizontalSeparator" Margin="3,0,3,0" Height="1" Grid.ColumnSpan="2" Fill="{TemplateBinding SeparatorBrush}" Stretch="Fill" VerticalAlignment="Bottom" Visibility="{TemplateBinding SeparatorVisibility}"/>
                        <ContentPresenter Margin="0,0,1,0" Grid.Column="1" Content="{TemplateBinding Content}" HorizontalAlignment="Left" VerticalAlignment="Center"/>
                        <Path x:Name="CurrentRowGlyph" Margin="8,0,8,0" Grid.RowSpan="2" Height="10" Width="6" Fill="#FF7CA9FD" Stretch="Fill" VerticalAlignment="Center" HorizontalAlignment="Center" Opacity="0" Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z "/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="data:DataGridRow">
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="data:DataGridRow">
                    <dataPrimitives:DataGridFrozenGrid x:Name="Root">
                        <Grid.Resources>
                            <Storyboard x:Key="DetailsVisibleTransition">
                                <DoubleAnimation Duration="00:00:0.1" Storyboard.TargetName="DetailsPresenter" Storyboard.TargetProperty="ContentHeight"/>
                            </Storyboard>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Normal AlternatingRow"/>
                                <vsm:VisualState x:Name="MouseOver"/>
                                <vsm:VisualState x:Name="Normal Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Selected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="MouseOver Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Selected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Selected" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="*"/>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="Auto"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <Rectangle x:Name="Selected" Grid.RowSpan="2" Grid.ColumnSpan="2" Fill="#FFA7CDF0" Stroke="#FF000000" StrokeDashArray="2" StrokeThickness="1" Opacity="0"/>
                        <dataPrimitives:DataGridRowHeader x:Name="RowHeader" Grid.RowSpan="3" dataPrimitives:DataGridFrozenGrid.IsFrozen="True"/>
                        <dataPrimitives:DataGridCellsPresenter x:Name="CellsPresenter" Grid.Column="1" dataPrimitives:DataGridFrozenGrid.IsFrozen="True"/>
                        <dataPrimitives:DataGridDetailsPresenter x:Name="DetailsPresenter" Grid.Column="1" Grid.Row="1"/>
                        <Rectangle x:Name="BottomGridLine" Height="1" Grid.Column="1" Grid.Row="2"/>
                    </dataPrimitives:DataGridFrozenGrid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="Button">
        <Setter Property="Foreground" Value="#FF042271"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Padding" Value="3"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgoundPressed_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledOverlay" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                    <GradientStop Color="#FF84B2D4"/>
                                    <GradientStop Color="#FFADC7DE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                    <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                    <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                    <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                    <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                        </Border>
                        <Border x:Name="BackgroundNorm_highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65"/>
                        <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                    <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                    <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundOver_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgoundPressed_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="DisabledVisualElement" Background="#3FFFFFFF" BorderBrush="#D8FFFFFF" CornerRadius="1.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                        <ContentPresenter
								x:Name="contentPresenter"
								Content="{TemplateBinding Content}"
								ContentTemplate="{TemplateBinding ContentTemplate}"
								VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
								Margin="{TemplateBinding Padding}"/>
                        <TextBlock Canvas.ZIndex="1"
                            	x:Name="DisabledOverlay"
                            	Text="{TemplateBinding Content}"
                            	Foreground="#FF8E96A2"
                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								Margin="{TemplateBinding Padding}"
                            	Visibility="Collapsed"/>
                        <Border x:Name="FocusVisualElement" Margin="-1" BorderBrush="#FFE99862" BorderThickness="1" CornerRadius="2.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="RepeatButton">
        <Setter Property="Foreground" Value="#FF042271"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Padding" Value="3"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="RepeatButton">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgoundPressed_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledOverlay" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                    <GradientStop Color="#FF84B2D4"/>
                                    <GradientStop Color="#FFADC7DE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                    <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                    <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                    <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                    <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                        </Border>
                        <Border x:Name="BackgroundNorm_highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65"/>
                        <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                    <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                    <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundOver_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgoundPressed_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="DisabledVisualElement" Background="#3FFFFFFF" BorderBrush="#D8FFFFFF" CornerRadius="1.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                        <ContentPresenter
								x:Name="contentPresenter"
								Content="{TemplateBinding Content}"
								ContentTemplate="{TemplateBinding ContentTemplate}"
								VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
								Margin="{TemplateBinding Padding}"/>
                        <TextBlock Canvas.ZIndex="1"
                            	x:Name="DisabledOverlay"
                            	Text="{TemplateBinding Content}"
                            	Foreground="#FF8E96A2"
                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								Margin="{TemplateBinding Padding}"
                            	Visibility="Collapsed"/>
                        <Border x:Name="FocusVisualElement" Margin="-1" BorderBrush="#FFE99862" BorderThickness="1" CornerRadius="2.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ToggleButton">
        <Setter Property="Foreground" Value="#FF042271"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Padding" Value="3"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ToggleButton">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                        <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="BackgoundPressed_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledOverlay" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="CheckStates">
                                <vsm:VisualState x:Name="Checked">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundChecked" Storyboard.TargetProperty="Opacity" To="0.84"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgoundChecked_Highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unchecked"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                    <GradientStop Color="#FF84B2D4"/>
                                    <GradientStop Color="#FFADC7DE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                    <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                    <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                    <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                    <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                        </Border>
                        <Border x:Name="BackgroundNorm_highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65"/>
                        <Border x:Name="BackgroundChecked" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFEC563" Offset="0.986"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgoundChecked_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                    <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                    <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundOver_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                    <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFEC563" Offset="0.986"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="BackgoundPressed_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Border x:Name="DisabledVisualElement" Background="#3FFFFFFF" BorderBrush="#D8FFFFFF" CornerRadius="1.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                        <ContentPresenter
								x:Name="contentPresenter"
								Content="{TemplateBinding Content}"
								ContentTemplate="{TemplateBinding ContentTemplate}"
								VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
								Margin="{TemplateBinding Padding}"/>
                        <TextBlock Canvas.ZIndex="1"
                            	x:Name="DisabledOverlay"
                            	Text="{TemplateBinding Content}"
                            	Foreground="#FF8E96A2"
                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								Margin="{TemplateBinding Padding}"
                            	Visibility="Collapsed"/>
                        <Border x:Name="FocusVisualElement" Margin="-1" Grid.RowSpan="2" BorderBrush="#FFE99862" BorderThickness="1" CornerRadius="2.75" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="HyperlinkButton">
        <Setter Property="Foreground" Value="#FF042271" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Cursor" Value="Hand"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="HyperlinkButton">
                    <Grid Cursor="{TemplateBinding Cursor}" Background="{TemplateBinding Background}">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="MouseOverText" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="NormalText" Storyboard.TargetProperty="Opacity" To="0"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="PressedText" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="NormalText" Storyboard.TargetProperty="Opacity" To="0"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledOverlay" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="NormalText" Storyboard.TargetProperty="Opacity" To="0"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <ContentPresenter 
	                                x:Name="contentPresenter"
	                                Content="{TemplateBinding Content}"
	                                ContentTemplate="{TemplateBinding ContentTemplate}"
	                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"									
	                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
									Margin="{TemplateBinding Padding}" 
									Visibility="Collapsed"/>
                        <TextBlock
	                            	x:Name="NormalText"
	                            	Text="{TemplateBinding Content}"
	                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}" 
									Foreground="{TemplateBinding Foreground}"
									Margin="{TemplateBinding Padding}"/>
                        <TextBlock
	                            	x:Name="MouseOverText"
	                            	Text="{TemplateBinding Content}"
	                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
	                            	TextDecorations="Underline"
	                            	Foreground="{TemplateBinding Foreground}"
									Margin="{TemplateBinding Padding}" 
									Opacity="0"/>
                        <TextBlock
	                            	x:Name="PressedText"
	                            	Text="{TemplateBinding Content}"
									HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
									VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
	                            	TextDecorations="Underline"
	                            	Foreground="#FFF28926"
									Margin="{TemplateBinding Padding}" 
									Opacity="0"/>
                        <TextBlock Canvas.ZIndex="1"
	                            	x:Name="DisabledOverlay"
	                            	Text="{TemplateBinding Content}"
	                            	Foreground="#FF8E96A2"
	                            	HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                            	VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
									Margin="{TemplateBinding Padding}"
	                            	Visibility="Collapsed"/>
                        <Rectangle x:Name="FocusVisualElement" Stroke="#4CF28926" StrokeThickness="1" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="CheckBox">
        <Setter Property="Foreground" Value="{StaticResource TextColor}"/>
        <Setter Property="FontSize" Value="12" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="Padding" Value="4,1,0,0"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="CheckBox">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="16"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BoxOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ColorAnimation Duration="0" Storyboard.TargetName="BoxOver" Storyboard.TargetProperty="(Shape.Stroke).(GradientBrush.GradientStops)[1].(GradientStop.Color)" To="#FFF28A27"/>
                                        <ColorAnimation Duration="0" Storyboard.TargetName="BoxOver" Storyboard.TargetProperty="(Shape.Stroke).(GradientBrush.GradientStops)[0].(GradientStop.Color)" To="#FFF4D9BE"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BoxOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundFill" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="CheckStates">
                                <vsm:VisualState x:Name="Checked">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CheckIcon" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BoxPress" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unchecked"/>
                                <vsm:VisualState x:Name="Indeterminate">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="IndeterminateIcon" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusedVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>

                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid HorizontalAlignment="Left" VerticalAlignment="Top">
                            <Rectangle x:Name="Background" Margin="1" Width="13" Height="13" RadiusX="0" RadiusY="0" Fill="#FFF4F4F4" Stroke="#FF868686" StrokeThickness="1"/>
                            <Rectangle x:Name="BoxFill" Width="9" Height="9" RadiusX="0" RadiusY="0" Fill="#FFCACFD5" StrokeThickness="1">
                                <Rectangle.Stroke>
                                    <LinearGradientBrush EndPoint="-0.007,-0.012" StartPoint="0.915,0.92">
                                        <GradientStop Color="#FFE4E5E9"/>
                                        <GradientStop Color="#FFA2ACB9" Offset="1"/>
                                    </LinearGradientBrush>
                                </Rectangle.Stroke>
                            </Rectangle>
                            <Rectangle x:Name="BackgroundFill" Margin="1" Width="13" Height="13" RadiusX="0" RadiusY="0" Fill="#FFDEEAFA" Stroke="#FF5577A3" StrokeThickness="1" Opacity="0"/>
                            <Rectangle x:Name="BoxOver" Margin="3" Width="9" Height="9" RadiusX="0" RadiusY="0" Fill="#FFFCE7AF" StrokeThickness="1" Opacity="0">
                                <Rectangle.Stroke>
                                    <LinearGradientBrush EndPoint="0.055,0.119" StartPoint="0.886,0.808">
                                        <GradientStop Color="#FFFCE7AF"/>
                                        <GradientStop Color="#FFFDDA81" Offset="1"/>
                                    </LinearGradientBrush>
                                </Rectangle.Stroke>
                            </Rectangle>
                            <Rectangle x:Name="BoxPress" Margin="3" Width="9" Height="9" RadiusX="0" RadiusY="0" StrokeThickness="1" Opacity="0">
                                <Rectangle.Stroke>
                                    <LinearGradientBrush EndPoint="0.055,0.119" StartPoint="0.886,0.808">
                                        <GradientStop Color="#FFF4D9BE"/>
                                        <GradientStop Color="#FFF28A27" Offset="1"/>
                                    </LinearGradientBrush>
                                </Rectangle.Stroke>
                            </Rectangle>
                            <Rectangle x:Name="BoxGradient" Width="7" Height="7" RadiusX="0" RadiusY="0" StrokeThickness="1">
                                <Rectangle.Fill>
                                    <LinearGradientBrush StartPoint="0.238,0.228" EndPoint="0.752,0.749">
                                        <GradientStop Color="#00F6F6F6" Offset="0.254" />
                                        <GradientStop Color="#53F8F8F8" Offset="0.54"/>
                                        <GradientStop Color="#BFFFFFFF" Offset="0.996" />
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>
                            <Rectangle x:Name="IndeterminateIcon" Width="5" Height="2" Fill="#FF405A78" HorizontalAlignment="Center" VerticalAlignment="Center" Visibility="Collapsed"/>
                            <Path x:Name="CheckIcon" Margin="0,3.333,3.833,0" Width="7" Height="9" Fill="#FF405A78" Stretch="Fill" VerticalAlignment="Top" HorizontalAlignment="Right" Data="M103.78572,598.96112 L105.09846,597.5661 L107.00806,600.16229 C107.00806,600.16229 109.91004,592.74463 109.91004,592.74463 C109.91004,592.74463 111.74678,593.79761 111.74678,593.79761 C111.74678,593.79761 107.88566,602.75848 107.88566,602.75848 L106.60118,602.75848 z" Visibility="Collapsed"/>
                            <Rectangle x:Name="FocusedVisualElement" RadiusX="0" RadiusY="0" Stroke="#FFE99862" StrokeThickness="1" Visibility="Collapsed"/>
                            <Rectangle x:Name="DisabledVisualElement" Margin="1" RadiusX="0" RadiusY="0" Fill="#3FFFFFFF" Visibility="Collapsed"/>
                            <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                                <ToolTipService.ToolTip>
                                    <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                        <ToolTip.Triggers>
                                            <EventTrigger RoutedEvent="Canvas.Loaded">
                                                <BeginStoryboard>
                                                    <Storyboard>
                                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                                <DiscreteObjectKeyFrame.Value>
                                                                    <system:Boolean>true</system:Boolean>
                                                                </DiscreteObjectKeyFrame.Value>
                                                            </DiscreteObjectKeyFrame>
                                                        </ObjectAnimationUsingKeyFrames>
                                                    </Storyboard>
                                                </BeginStoryboard>
                                            </EventTrigger>
                                        </ToolTip.Triggers>
                                    </ToolTip>
                                </ToolTipService.ToolTip>
                                <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                    <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                    <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                                </Grid>
                            </Border>

                        </Grid>
                        <ContentPresenter
	                                Grid.Column="1"
	                                x:Name="contentPresenter"
	                                Content="{TemplateBinding Content}"
	                                ContentTemplate="{TemplateBinding ContentTemplate}"
	                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
	                                Margin="{TemplateBinding Padding}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="RadioButton">
        <Setter Property="Foreground" Value="{StaticResource TextColor}"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="Padding" Value="4,1,0,0"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="RadioButton">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="16"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CircleOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CirclePress" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="CheckStates">
                                <vsm:VisualState x:Name="Checked">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CheckIcon" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unchecked"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusedVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>

                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid HorizontalAlignment="Left" VerticalAlignment="Top">
                            <Ellipse x:Name="Background" Margin="1" Width="14" Height="14" Fill="#FFEDEDEE" Stroke="#FF597AA5" StrokeThickness="1"/>
                            <Ellipse x:Name="CircleFill" Margin="3.045,3.157,2.955,2.843" StrokeThickness="1">
                                <Ellipse.Stroke>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFB3B8BD" Offset="0.004"/>
                                        <GradientStop Color="#FFE0E0E0" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Stroke>
                                <Ellipse.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFC8CDD2"/>
                                        <GradientStop Color="#FFF2F2F2" Offset="0.531"/>
                                        <GradientStop Color="#FFF5F5F5" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Fill>
                            </Ellipse>
                            <Ellipse x:Name="CircleOver" Margin="2.847,2.847,3.153,3.153" StrokeThickness="1" Opacity="0" >
                                <Ellipse.Stroke>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFE3CF87" Offset="0.004"/>
                                        <GradientStop Color="#FFFCF0D3" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Stroke>
                                <Ellipse.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFE3DBA9"/>
                                        <GradientStop Color="#FFFEF5DD" Offset="0.531"/>
                                        <GradientStop Color="#FFFEF5DD" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Fill>
                            </Ellipse>
                            <Ellipse x:Name="CirclePress" Margin="2.73,2.73,3.27,3.27" StrokeThickness="1" Opacity="0" >
                                <Ellipse.Stroke>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFAC773F" Offset="0.004"/>
                                        <GradientStop Color="#FFC8B5A3" Offset="0.987"/>
                                    </LinearGradientBrush>
                                </Ellipse.Stroke>
                                <Ellipse.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFC8CDD2"/>
                                        <GradientStop Color="#FFF2F2F2" Offset="0.531"/>
                                        <GradientStop Color="#FFF5F5F5" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Fill>
                            </Ellipse>
                            <Ellipse x:Name="CheckIcon" Margin="4.47,4.498,3.53,3.502" StrokeThickness="1" Visibility="Collapsed" Stroke="#FFDA8229">
                                <Ellipse.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FFFDDC8B" Offset="0.013"/>
                                        <GradientStop Color="#FFFDDC8B" Offset="0.188"/>
                                        <GradientStop Color="#FFF9952F" Offset="0.491"/>
                                        <GradientStop Color="#FFF9954A" Offset="1"/>
                                    </LinearGradientBrush>
                                </Ellipse.Fill>
                            </Ellipse>
                            <Ellipse x:Name="DisabledVisualElement" Width="14" Height="14" Fill="#FFFFFFFF" Stroke="#FFFFFFFF" Opacity="0.35" Visibility="Collapsed"/>
                            <Ellipse x:Name="FocusedVisualElement" Width="16" Height="16" Stroke="#FFE69762" StrokeThickness="1" IsHitTestVisible="false" Visibility="Collapsed" />
                            <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                                <ToolTipService.ToolTip>
                                    <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                        <ToolTip.Triggers>
                                            <EventTrigger RoutedEvent="Canvas.Loaded">
                                                <BeginStoryboard>
                                                    <Storyboard>
                                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                                <DiscreteObjectKeyFrame.Value>
                                                                    <system:Boolean>true</system:Boolean>
                                                                </DiscreteObjectKeyFrame.Value>
                                                            </DiscreteObjectKeyFrame>
                                                        </ObjectAnimationUsingKeyFrames>
                                                    </Storyboard>
                                                </BeginStoryboard>
                                            </EventTrigger>
                                        </ToolTip.Triggers>
                                    </ToolTip>
                                </ToolTipService.ToolTip>
                                <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                    <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                    <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                                </Grid>
                            </Border>

                        </Grid>
                        <ContentPresenter
	                                Grid.Column="1"
	                                x:Name="contentPresenter"
	                                Content="{TemplateBinding Content}"
	                                ContentTemplate="{TemplateBinding ContentTemplate}"
	                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
	                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
	                                Margin="{TemplateBinding Padding}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controlsPrimitives:CalendarButton" >
        <Setter Property="Background" Value="#FFFAD57A" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="MinWidth" Value="35" />
        <Setter Property="MinHeight" Value="35" />
        <Setter Property="HorizontalContentAlignment" Value="Center" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controlsPrimitives:CalendarButton">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates" >
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.1" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="Opacity" To=".75" />
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="Opacity" To=".75" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates" >
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Unselected" />
                                <vsm:VisualState x:Name="Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SelectedBackground" Storyboard.TargetProperty="Opacity" To="1" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ActiveStates" >
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Active" />
                                <vsm:VisualState x:Name="Inactive">
                                    <Storyboard>
                                        <ColorAnimation Duration="0" Storyboard.TargetName="selectedText" Storyboard.TargetProperty="Color" To="#FF848484"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="CalendarButtonFocusStates" >
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="CalendarButtonFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CalendarButtonFocusVisual" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="CalendarButtonUnfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="SelectedBackground" RadiusX="1" RadiusY="1" Fill="{TemplateBinding Background}" Opacity="0"/>
                        <Rectangle x:Name="Background" RadiusX="1" RadiusY="1" Fill="{TemplateBinding Background}"  Opacity="0"/>
                        <ContentControl x:Name="NormalText" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False">
                            <ContentControl.Foreground>
                                <SolidColorBrush x:Name="selectedText" Color="#FF000000" />
                            </ContentControl.Foreground>
                        </ContentControl>
                        <Rectangle x:Name="CalendarButtonFocusVisual" RadiusX="1" RadiusY="1" Stroke="#FFF28926" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controlsPrimitives:CalendarDayButton" >
        <Setter Property="Background" Value="#FFFAD57A" />
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="11" />
        <Setter Property="MinWidth" Value="5" />
        <Setter Property="MinHeight" Value="5" />
        <Setter Property="HorizontalContentAlignment" Value="Center" />
        <Setter Property="VerticalContentAlignment" Value="Center" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controlsPrimitives:CalendarDayButton">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.1" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="Opacity" To=".75" />
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Background" Storyboard.TargetProperty="Opacity" To=".75" />
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="NormalText" Storyboard.TargetProperty="Opacity" To=".35" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Unselected" />
                                <vsm:VisualState x:Name="Selected">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="SelectedBackground" Storyboard.TargetProperty="Opacity" To="1" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="CalendarButtonFocusStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="CalendarButtonFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DayButtonFocusVisual" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="CalendarButtonUnfocused"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ActiveStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Active" />
                                <vsm:VisualState x:Name="Inactive">
                                    <Storyboard>
                                        <ColorAnimation Duration="0" Storyboard.TargetName="selectedText" Storyboard.TargetProperty="Color" To="#FF848484"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="DayStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="RegularDay" />
                                <vsm:VisualState x:Name="Today">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="TodayBackground" Storyboard.TargetProperty="Opacity" To=".70" />
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="BlackoutDayStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="NormalDay" />
                                <vsm:VisualState x:Name="BlackoutDay">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="Blackout" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="TodayBackground" RadiusX="1" RadiusY="1" Fill="#FFF28926" Opacity="0"/>
                        <Rectangle x:Name="SelectedBackground" RadiusX="1" RadiusY="1" Fill="{TemplateBinding Background}" Opacity="0"/>
                        <Rectangle x:Name="Background" RadiusX="1" RadiusY="1" Fill="{TemplateBinding Background}" Opacity="0" />
                        <ContentControl x:Name="NormalText" Margin="4,2,3,1" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False">
                            <ContentControl.Foreground>
                                <SolidColorBrush x:Name="selectedText" Color="#FF000000" />
                            </ContentControl.Foreground>
                        </ContentControl>
                        <Path x:Name="Blackout" Margin="3" Opacity="0.2" Fill="#FF848484" Stretch="Fill" Data="M8.1772461,11.029181 L10.433105,11.029181 L11.700684,12.801641 L12.973633,11.029181 L15.191895,11.029181 L12.844727,13.999395 L15.21875,17.060919 L12.962891,17.060919 L11.673828,15.256231 L10.352539,17.060919 L8.1396484,17.060919 L10.519043,14.042364 z" Visibility="Collapsed" />
                        <Rectangle x:Name="DayButtonFocusVisual" RadiusX="1" RadiusY="1" Stroke="#FFF28926" IsHitTestVisible="false" Visibility="Collapsed" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controlsPrimitives:CalendarItem">
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controlsPrimitives:CalendarItem">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="0">
                            <Grid Margin="0,0,0,15">
                                <Grid.Resources>
                                    <ControlTemplate x:Key="PreviousButtonTemplate" TargetType="Button">
                                        <Grid Cursor="Hand">
                                            <vsm:VisualStateManager.VisualStateGroups>
                                                <vsm:VisualStateGroup x:Name="CommonStates">
                                                    <vsm:VisualState x:Name="Normal"/>
                                                    <vsm:VisualState x:Name="MouseOver">
                                                        <Storyboard>
                                                            <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="OverColor" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                            </ObjectAnimationUsingKeyFrames>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                    <vsm:VisualState x:Name="Disabled">
                                                        <Storyboard>
                                                            <DoubleAnimation Duration="0" Storyboard.TargetName="NormColor" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                </vsm:VisualStateGroup>
                                            </vsm:VisualStateManager.VisualStateGroups>
                                            <Grid x:Name="NormColor">
                                                <Path Margin="5,0,0,0" Height="10" Width="6" Fill="#FF6F9DD9" Stretch="Fill" HorizontalAlignment="Left" VerticalAlignment="Center" Data="M288.75,232.25 L288.75,240.625 L283,236.625 z"/>
                                            </Grid>
                                            <Grid x:Name="OverColor" Visibility="Collapsed">
                                                <Rectangle Width="18" Height="18" Fill="#FFFAD57A" StrokeThickness="0.5" HorizontalAlignment="Left"/>
                                                <Path Margin="5,0,0,0" Height="10" Width="6" Fill="#FFF28926" Stretch="Fill" Stroke="#FF848484" StrokeThickness="0.5"  HorizontalAlignment="Left" Data="M288.75,232.25 L288.75,240.625 L283,236.625 z"/>
                                            </Grid>
                                        </Grid>
                                    </ControlTemplate>
                                    <ControlTemplate x:Key="NextButtonTemplate" TargetType="Button">
                                        <Grid Cursor="Hand">
                                            <vsm:VisualStateManager.VisualStateGroups>
                                                <vsm:VisualStateGroup x:Name="CommonStates">
                                                    <vsm:VisualState x:Name="Normal"/>
                                                    <vsm:VisualState x:Name="MouseOver">
                                                        <Storyboard>
                                                            <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="OverColor" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                            </ObjectAnimationUsingKeyFrames>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                    <vsm:VisualState x:Name="Disabled">
                                                        <Storyboard>
                                                            <DoubleAnimation Duration="0" Storyboard.TargetName="NormColor" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                </vsm:VisualStateGroup>
                                            </vsm:VisualStateManager.VisualStateGroups>
                                            <Grid x:Name="NormColor">
                                                <Path Margin="5,0,0,0" Height="10" Width="6" Fill="#FF6F9DD9" Stretch="Fill" HorizontalAlignment="Left" Data="M282.875,231.875 L282.875,240.375 L288.625,236 z"/>
                                            </Grid>
                                            <Grid x:Name="OverColor" Visibility="Collapsed">
                                                <Rectangle Width="18" Height="18" Fill="#FFFAD57A" HorizontalAlignment="Left"/>
                                                <Path Margin="5,0,0,0" Height="10" Width="6" Fill="#FFF28926" Stretch="Fill" Stroke="#FF848484" StrokeThickness="0.5" HorizontalAlignment="Left" Data="M282.875,231.875 L282.875,240.375 L288.625,236 z"/>
                                            </Grid>
                                        </Grid>
                                    </ControlTemplate>
                                    <ControlTemplate x:Key="HeaderButtonTemplate" TargetType="Button">
                                        <Grid Cursor="Hand" HorizontalAlignment="Center" VerticalAlignment="Center">
                                            <vsm:VisualStateManager.VisualStateGroups>
                                                <vsm:VisualStateGroup x:Name="CommonStates">
                                                    <vsm:VisualState x:Name="Normal"/>
                                                    <vsm:VisualState x:Name="MouseOver">
                                                        <Storyboard>
                                                            <DoubleAnimation Duration="0" Storyboard.TargetName="rectangle" Storyboard.TargetProperty="Opacity" To="1"/>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                    <vsm:VisualState x:Name="Disabled">
                                                        <Storyboard>
                                                            <DoubleAnimation Duration="0" Storyboard.TargetName="buttonContent" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                        </Storyboard>
                                                    </vsm:VisualState>
                                                </vsm:VisualStateGroup>
                                            </vsm:VisualStateManager.VisualStateGroups>
                                            <Rectangle x:Name="rectangle" Margin="-2,2,-2,8" Fill="#FFFAD57A" Stretch="Fill" Opacity="0" />
                                            <ContentControl x:Name="buttonContent" Margin="1,5,1,9" HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" IsTabStop="False"/>
                                        </Grid>
                                    </ControlTemplate>
                                    <DataTemplate x:Name="DayTitleTemplate">
                                        <StackPanel Orientation="Vertical">
                                            <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding}"/>
                                            <Rectangle Height="1" Fill="#FF9AC6FF" Stretch="Fill" />
                                        </StackPanel>
                                    </DataTemplate>
                                </Grid.Resources>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="Auto"/>
                                    <ColumnDefinition Width="Auto"/>
                                    <ColumnDefinition Width="Auto"/>
                                </Grid.ColumnDefinitions>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition Height="*"/>
                                    <RowDefinition Height="Auto"/>
                                </Grid.RowDefinitions>
                                <Grid Margin="4,-3,4,0" Grid.ColumnSpan="3" Height="18">
                                    <Rectangle x:Name="HeaderBackground" Fill="#FFBFDBFF" Stretch="Fill" />
                                </Grid>
                                <Button x:Name="PreviousButton" Margin="4,-3,4,0" Width="18" HorizontalAlignment="Left" Template="{StaticResource PreviousButtonTemplate}" Visibility="Collapsed"/>
                                <Button x:Name="HeaderButton" Margin="0,3,0,0" Grid.Column="1" HorizontalAlignment="Center" Template="{StaticResource HeaderButtonTemplate}" />
                                <Button x:Name="NextButton" Margin="4,-3,4,0" Grid.Column="2" Width="18" HorizontalAlignment="Right" Template="{StaticResource NextButtonTemplate}" Visibility="Collapsed"/>
                                <Grid x:Name="MonthView" Margin="18,-4,18,0" Grid.ColumnSpan="3" Grid.Row="1" HorizontalAlignment="Center" Visibility="Collapsed">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                    </Grid.ColumnDefinitions>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                    </Grid.RowDefinitions>
                                </Grid>
                                <Grid x:Name="YearView" Margin="15,-8,14,10" Grid.ColumnSpan="3" Grid.Row="1" HorizontalAlignment="Center" Visibility="Collapsed">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="Auto"/>
                                    </Grid.ColumnDefinitions>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                    </Grid.RowDefinitions>
                                </Grid>
                            </Grid>
                        </Border>
                        <Rectangle x:Name="DisabledVisual" RadiusX="0" RadiusY="0" Fill="#FFCACFD5" Stretch="Fill" Opacity="0.2" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:Calendar">
        <Setter Property="Background" Value="#FFFFFFFF" />
        <Setter Property="BorderBrush" Value="#FF848484"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Padding" Value="4" />
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:Calendar">
                    <StackPanel x:Name="Root" HorizontalAlignment="Center" VerticalAlignment="Top">
                        <controlsPrimitives:CalendarItem x:Name="CalendarItem" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Foreground="{TemplateBinding Foreground}" IsEnabled="True" />
                    </StackPanel>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="ProgressBar">
        <Setter Property="Maximum" Value="100"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ProgressBar">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Determinate"/>
                                <vsm:VisualState x:Name="Indeterminate">
                                    <Storyboard RepeatBehavior="Forever">
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="IndeterminateRoot" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DeterminateRoot" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="IndeterminateGradientFill" Storyboard.TargetProperty="(Shape.Fill).(LinearGradientBrush.Transform).(TransformGroup.Children)[0].X">
                                            <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:.5" Value="20"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border Background="#FFB2B7BA" CornerRadius="3"/>
                        <Border x:Name="ProgressBarTrack" BorderThickness="1" CornerRadius="3" Opacity="0.825">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFFFFFFF"/>
                                    <GradientStop Color="#FFD8D8D8" Offset="0.327"/>
                                    <GradientStop Color="#FFDADADA" Offset="0.488"/>
                                    <GradientStop Color="#FFBEBEBE" Offset="0.539"/>
                                    <GradientStop Color="#FFD6D6D6" Offset="0.77"/>
                                    <GradientStop Color="#FFFFFFFF" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFBBBBBB" Offset="0"/>
                                    <GradientStop Color="#FF7E7E7E" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                        <Grid x:Name="ProgressBarRootGrid">
                            <Grid x:Name="IndeterminateRoot" Visibility="Collapsed">
                                <Rectangle x:Name="IndeterminateSolidFill" Margin="1" Fill="#FF6EA4FD" RadiusX="2" RadiusY="2" Width="Auto"/>
                                <Rectangle x:Name="ProgressBarRootGradient" Margin="1" Canvas.ZIndex="1" RadiusX="1.5" RadiusY="1.5">
                                    <Rectangle.Fill>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#F6BCD5FF" Offset="0.046"/>
                                            <GradientStop Color="#96D4E4FF" Offset="0.18"/>
                                            <GradientStop Color="#4FFFFFFF" Offset="0.512"/>
                                            <GradientStop Color="#00D6D6D6" Offset="0.521"/>
                                            <GradientStop Color="#BABCD5FF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Rectangle.Fill>
                                </Rectangle>
                                <Rectangle x:Name="IndeterminateGradientFill" Margin="1" StrokeThickness="1" RadiusX="2" RadiusY="2" Opacity="0.7">
                                    <Rectangle.Fill>
                                        <LinearGradientBrush EndPoint="0,1" StartPoint="20,1" MappingMode="Absolute" SpreadMethod="Repeat">
                                            <LinearGradientBrush.Transform>
                                                <TransformGroup>
                                                    <TranslateTransform X="0"/>
                                                    <SkewTransform AngleX="-10"/>
                                                </TransformGroup>
                                            </LinearGradientBrush.Transform>
                                            <GradientStop Color="#FFBCD5FF" Offset="0.088"/>
                                            <GradientStop Color="#006EA4FD" Offset="0.475"/>
                                            <GradientStop Color="#FFBCD5FF" Offset="0.899"/>
                                        </LinearGradientBrush>
                                    </Rectangle.Fill>
                                </Rectangle>
                            </Grid>
                            <Grid x:Name="DeterminateRoot">
                                <Rectangle x:Name="ProgressBarIndicator" Margin="1" RadiusX="1.5" RadiusY="1.5" HorizontalAlignment="Left" Opacity="0.83">
                                    <Rectangle.Fill>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFC6D6EC" Offset="0"/>
                                            <GradientStop Color="#FFBDD6FF" Offset="0.502"/>
                                            <GradientStop Color="#FF71A7FD" Offset="0.522"/>
                                            <GradientStop Color="#FF94BDFD" Offset="0.763"/>
                                            <GradientStop Color="#FFA9CAFF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Rectangle.Fill>
                                </Rectangle>
                            </Grid>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="Thumb">
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Thumb">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Over" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Press" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Path x:Name="Base" Margin="1,1.312,1,0.375" Fill="#FFC1C1C1" Stretch="Fill" Stroke="#FF496FA2" StrokeThickness="1" StrokeLineJoin="Round" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4266928 L-6.6465902,1.7712332 L-9.9818907,1.433604 z"/>
                        <Path x:Name="Over" Margin="2,2.312,2,1.375" Fill="#FFF5C94F" Stretch="Fill" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4276805 L-6.6465902,1.7722208 L-9.9818907,1.4345917 z" Opacity="0"/>
                        <Path x:Name="Press" Margin="2,2.312,2,1.375" Fill="#FFFD8F25" Stretch="Fill" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4276805 L-6.6465902,1.7722208 L-9.9818907,1.4345917 z" Opacity="0"/>
                        <Path x:Name="whiteGradient" Margin="2,2.312,2,1.375" Stretch="Fill" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4276805 L-6.6465902,1.7722208 L-9.9818907,1.4345917 z">
                            <Path.Fill>
                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.563,0.979">
                                    <GradientStop Color="#5FFFFFFF" Offset="0"/>
                                    <GradientStop Color="#5FFFFFFF" Offset="0.259"/>
                                    <GradientStop Color="#00FFFFFF" Offset="0.393"/>
                                    <GradientStop Color="#00FFFFFF" Offset="0.643"/>
                                    <GradientStop Color="#75FFFFFF" Offset="0.75"/>
                                    <GradientStop Color="#99FFFFFF" Offset="1"/>
                                </LinearGradientBrush>
                            </Path.Fill>
                        </Path>
                        <Path x:Name="Line" Margin="-1,-2,0,0" Height="10" Width="1" Stretch="Fill" Stroke="#FF6B81A0" StrokeThickness="1" Data="M5.4375,2.6875 L5.4375,12.1875" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                        <Path x:Name="Line2" Margin="0,-2,-1,0" Height="10" Width="1" Stretch="Fill" Stroke="#FFFFFFFF" StrokeThickness="1" Data="M5.4375,2.6875 L5.4375,12.1875" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                        <Path x:Name="DisabledVisualElement" Margin="1,1.312,1,0.375" Fill="#FFFFFFFF" Stroke="#FFFFFFFF" StrokeThickness="1" StrokeLineJoin="Round" Stretch="Fill" Opacity="0.1" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4266928 L-6.6465902,1.7712332 L-9.9818907,1.433604 z" IsHitTestVisible="false" Visibility="Collapsed" />
                        <Path x:Name="FocusVisualElement" Stretch="Fill" Stroke="#FFE99862" StrokeThickness="1" StrokeLineJoin="Round" Data="M-9.958333,0.78716499 L-3.204694,0.78717428 L-3.2052999,1.4276805 L-6.6465902,1.7722208 L-9.9818907,1.4345917 z" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    
    
    
    <Style TargetType="Slider">
        <Setter Property="Maximum" Value="10" />
        <Setter Property="Minimum" Value="0" />
        <Setter Property="Value" Value="0" />
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Slider">
                    <Grid x:Name="Root">
                        <Grid.Resources>
                            <ControlTemplate x:Key="RepeatButtonTemplate">
                                <Grid x:Name="Root" Background="Transparent" Opacity="0"/>
                            </ControlTemplate>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Storyboard.TargetName="Root" Storyboard.TargetProperty="(UIElement.Opacity)" To="0.65"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>

                        <!-- Horizontal Template -->
                        <Grid x:Name="HorizontalTemplate" Visibility="Collapsed">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto"/>
                                <ColumnDefinition Width="Auto"/>
                                <ColumnDefinition Width="*"/>
                            </Grid.ColumnDefinitions>

                            <!-- Track Layer -->
                            <Rectangle Margin="7.5,0,7.5,0" Grid.Column="0" Grid.ColumnSpan="3" Height="6" RadiusX="3" RadiusY="3">
                                <Rectangle.Fill>
                                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                        <GradientStop Color="#FF324D70" Offset="0.493"/>
                                        <GradientStop Color="#FF6A8BB6" Offset="1"/>
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>

                            <!-- Repeat Buttons + Thumb -->
                            <RepeatButton x:Name="HorizontalTrackLargeChangeDecreaseRepeatButton" Grid.Column="0" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}"/>
                            <Thumb x:Name="HorizontalThumb" Height="21" Width="15" Grid.Column="1" IsTabStop="True"/>
                            <RepeatButton x:Name="HorizontalTrackLargeChangeIncreaseRepeatButton" Grid.Column="2" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}"/>
                        </Grid>

                        <!-- Vertical Template -->
                        <Grid x:Name="VerticalTemplate" Visibility="Collapsed">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="*"/>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto"/>
                            </Grid.RowDefinitions>

                            <!-- Track Layer -->
                            <Rectangle Margin="0,7.5,0,7.5" Grid.Row="0" Grid.RowSpan="3" Width="6" RadiusX="3" RadiusY="3">
                                <Rectangle.Fill>
                                    <LinearGradientBrush EndPoint="1.11,0.5" StartPoint="0.111,0.5">
                                        <GradientStop Color="#FF324D70" Offset="0.433"/>
                                        <GradientStop Color="#FF6A8BB6" Offset="0.817"/>
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>

                            <!-- Repeat Buttons + Thumb -->
                            <RepeatButton x:Name="VerticalTrackLargeChangeDecreaseRepeatButton" Grid.Row="2" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}"/>
                            <Thumb x:Name="VerticalThumb" Height="21" Width="15" Grid.Row="1" IsTabStop="True" RenderTransformOrigin="0.5,0.5">
                                <Thumb.RenderTransform>
                                    <TransformGroup>
                                        <ScaleTransform/>
                                        <SkewTransform/>
                                        <RotateTransform Angle="-90"/>
                                        <TranslateTransform Y="3" X="0"/>
                                    </TransformGroup>
                                </Thumb.RenderTransform>
                            </Thumb>
                            <RepeatButton x:Name="VerticalTrackLargeChangeIncreaseRepeatButton" Grid.Row="0" IsTabStop="False" Template="{StaticResource RepeatButtonTemplate}"/>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controlsPrimitives:DatePickerTextBox">
        <Setter Property="SelectionBackground" Value="#FF88C3FF"/>
        <Setter Property="SelectionForeground" Value="#FF000000"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controlsPrimitives:DatePickerTextBox">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.1" To="MouseOver"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard/>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="WatermarkStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Unwatermarked"/>
                                <vsm:VisualState x:Name="Watermarked">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Watermark" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="ContentElement" Storyboard.TargetProperty="Opacity" To="0"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Unfocused"/>
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid x:Name="WatermarkContent" Background="{TemplateBinding Background}">
                            <Border x:Name="ContentElement2" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
                                <ContentControl x:Name="Watermark" Foreground="#FFB1B5BA" Padding="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" Content="{TemplateBinding Watermark}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="Center" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="Center" IsTabStop="False" IsHitTestVisible="False" Opacity="0"/>
                            </Border>
                            <Border x:Name="ContentElement" Padding="{TemplateBinding Padding}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="Center"/>
                            <Border x:Name="FocusVisual" Margin="-1,-1,-22,-1" BorderBrush="#FFE99862" BorderThickness="1,1,0.5,1" CornerRadius="1" IsHitTestVisible="False" Visibility="Collapsed"/>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:DatePicker">
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="SelectionBackground" Value="#FF88C3FF"/>
        <Setter Property="FontFamily" Value="Trebuchet MS" />
        <Setter Property="FontSize" Value="12" />
        <Setter Property="Padding" Value="4,0,1,0"/>
        <Setter Property="BorderBrush" Value="#FF848484"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:DatePicker">
                    <Grid>
                        <Grid.Resources>
                            <ControlTemplate x:Key="DropDownButtonTemplate" TargetType="Button">
                                <Grid>
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="0:0:0.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="0:0:0.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#FF3C7FB1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPress" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#FF3C7FB1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisual" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid>
                                        <Border x:Name="Background" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="0,1,1,1" CornerRadius="0"/>
                                        <Border x:Name="BackgroundGradient" Margin="2" BorderBrush="#FFFFFFFF" BorderThickness="1" CornerRadius="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                    <GradientStop Color="#FFF6F6F6" Offset="0"/>
                                                    <GradientStop Color="#FFE8E6E6" Offset="0.507"/>
                                                    <GradientStop Color="#FFCDCDCD" Offset="0.512"/>
                                                    <GradientStop Color="#FFCFCFCF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="BackgroundOver" Margin="2" CornerRadius="0" Opacity="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                    <GradientStop Color="#FFE2E2E2" Offset="0"/>
                                                    <GradientStop Color="#FFEAF6FD" Offset="0.101"/>
                                                    <GradientStop Color="#FFE2F5FE" Offset="0.512"/>
                                                    <GradientStop Color="#FFA2E1FF" Offset="0.53"/>
                                                    <GradientStop Color="#FFAFDBF1" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="BackgroundPress" Margin="2" BorderThickness="1" CornerRadius="0" Opacity="0">
                                            <Border.BorderBrush>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFACB8BD"/>
                                                    <GradientStop Color="#FF82BDD8" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.BorderBrush>
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                    <GradientStop Color="#FFE2E2E2" Offset="0"/>
                                                    <GradientStop Color="#FFCAE7F4" Offset="0.097"/>
                                                    <GradientStop Color="#FFBDEAFF" Offset="0.521"/>
                                                    <GradientStop Color="#FF76D3FF" Offset="0.53"/>
                                                    <GradientStop Color="#FF8CCAEB" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="Highlight" Margin="1" BorderBrush="#FF707070" BorderThickness="1" CornerRadius="0"/>
                                        <Border x:Name="DisabledVisual" Background="#FF848484" CornerRadius="0" Opacity="0.65" Visibility="Collapsed"/>
                                        <Path x:Name="BtnArrow" Margin="0,1,0,0" Height="4" Width="8" Fill="#FF000000" Stretch="Uniform" Data="F1 M 301.14,-189.041L 311.57,-189.041L 306.355,-182.942L 301.14,-189.041 Z " HorizontalAlignment="Center" VerticalAlignment="Center" />
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <controlsPrimitives:DatePickerTextBox x:Name="TextBox" Margin="0,0,21,0" Height="22" Background="{TemplateBinding Background}" SelectionBackground="{TemplateBinding SelectionBackground}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1,1,0,1" Foreground="{TemplateBinding Foreground}" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" Padding="{TemplateBinding Padding}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/>
                        <Button x:Name="Button" Width="22" Height="22" BorderBrush="{TemplateBinding BorderBrush}" Template="{StaticResource DropDownButtonTemplate}" HorizontalAlignment="Right"/>
                        <Rectangle x:Name="DisabledVisualElement" Fill="#A5FFFFFF" IsHitTestVisible="false" Visibility="Collapsed" />
                        <Popup x:Name="Popup" Margin="0,0,-1,0" VerticalAlignment="Bottom"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:TabItem">
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Padding" Value="10,6,10,6"/>
        <Setter Property="MinWidth" Value="5"/>
        <Setter Property="MinHeight" Value="5"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:TabItem">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.1" To="MouseOver"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="TopUnselectedOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="LeftUnselectedOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="RightUnselectedOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BottomUnselectedOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="TopUnselectedBorderOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="BottomUnselectedBorderOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="LeftUnselectedBorderOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="RightUnselectedBorderOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualBottomSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualBottomUnSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualLeftSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualLeftUnSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualRightSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualRightUnSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualTopSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualTopUnSelected" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates">
                                <vsm:VisualState x:Name="Unselected"/>
                                <vsm:VisualState x:Name="Selected"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualBottom" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualLeft" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualRight" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualTop" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid x:Name="TemplateTopSelected" Margin="2,0,2,0" Canvas.ZIndex="1" Visibility="Collapsed">
                            <Grid Margin="1,0,1,0">
                                <Border x:Name="BackgroundTop" BorderBrush="#FFF3F8FF" BorderThickness="2,0,2,0" CornerRadius="3,3,0,0">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFEFF6FE" Offset="0"/>
                                            <GradientStop Color="#FFE0EAF6" Offset="0.384"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BorderTop" BorderThickness="2,0,2,0" CornerRadius="3,3,0,0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,-0.5">
                                            <GradientStop Color="#FFECF9FA" Offset="0"/>
                                            <GradientStop Color="#FFB4E0F4" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="HighlightTop" Margin="2,0,2,0" BorderThickness="1,3,1,0" CornerRadius="1.25,1.25,0,0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFF3F8FF" Offset="0"/>
                                            <GradientStop Color="#D8ECF8FC" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BorderTop2" Margin="-1,0,-1,0" BorderBrush="#FF9ABBE6" BorderThickness="1,1,1,0" CornerRadius="3,3,0,0" IsHitTestVisible="false"/>
                                <Border x:Name="FocusVisualTop" Margin="-1,0,-1,0" BorderThickness="3,2,3,0" CornerRadius="3,3,0,0" Visibility="Collapsed">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#99F7C53B" Offset="0"/>
                                            <GradientStop Color="#99F2B93F" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <ContentControl x:Name="HeaderTopSelected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="{TemplateBinding Foreground}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualTopSelected" Margin="1,0,1,0" Background="#8CFFFFFF" CornerRadius="3,3,0,0" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateTopUnselected" Margin="2,0,2,0" Visibility="Collapsed">
                            <Grid Margin="1,0,1,0">
                                <Border x:Name="TopUnselectedOver" BorderBrush="#FFDDEFFF" BorderThickness="1,1,1,0" CornerRadius="2.21,2.21,.5,.5" Opacity="0">
                                    <Border.Background>
                                        <RadialGradientBrush GradientOrigin="0.503,1.06">
                                            <RadialGradientBrush.RelativeTransform>
                                                <TransformGroup>
                                                    <ScaleTransform CenterX="0.5" CenterY="0.5" ScaleX="2.06" ScaleY="2.418"/>
                                                    <SkewTransform CenterX="0.5" CenterY="0.5"/>
                                                    <RotateTransform CenterX="0.5" CenterY="0.5" Angle="-180"/>
                                                    <TranslateTransform X="0" Y="0.315"/>
                                                </TransformGroup>
                                            </RadialGradientBrush.RelativeTransform>
                                            <GradientStop Color="#00FFFFFF" Offset="0.362"/>
                                            <GradientStop Color="#AEE8E6E6" Offset="0.496"/>
                                            <GradientStop Color="#F2E7D39C" Offset="0.629"/>
                                        </RadialGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="TopUnselectedBorderOver" Margin="-1,-1,-1,0.5" BorderBrush="#FF9FBCF0" BorderThickness="1,1,1,0" CornerRadius="3.5,3.5,0,0" Opacity="0"/>
                                <ContentControl x:Name="HeaderTopUnselected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="#FFFFFFFF" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualTopUnSelected" Margin="1,0,1,0" Background="#8CFFFFFF" CornerRadius="3,3,0,0" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateBottomSelected" Margin="2,0,2,0" Canvas.ZIndex="1" Visibility="Collapsed">
                            <Grid Margin="1,0,1,0">
                                <Border x:Name="BackgroundBottom" BorderBrush="#FFF3F8FF" BorderThickness="2,0,2,0" CornerRadius="0,0,3,3">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                            <GradientStop Color="#FFEFF6FE" Offset="0"/>
                                            <GradientStop Color="#FFE0EAF6" Offset="0.384"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BorderBottom" BorderThickness="2,0,2,0" CornerRadius="0,0,3,3">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,-0.5" StartPoint="0.5,1">
                                            <GradientStop Color="#FFECF9FA" Offset="0"/>
                                            <GradientStop Color="#FFB4E0F4" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="HighlightBottom" Margin="2,0,2,0" BorderThickness="1,0,1,3" CornerRadius="0,0,1.25,1.25">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                            <GradientStop Color="#FFF3F8FF" Offset="0"/>
                                            <GradientStop Color="#D8ECF8FC" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BorderBottom2" Margin="-1,0,-1,0" BorderBrush="#FF9ABBE6" BorderThickness="1,0,1,1" CornerRadius="0,0,3,3" IsHitTestVisible="false"/>
                                <Border x:Name="FocusVisualBottom" Margin="-1,0,-1,0" BorderThickness="3,0,3,2" CornerRadius="0,0,3,3" Visibility="Collapsed">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#99F7C53B" Offset="0"/>
                                            <GradientStop Color="#99F2B93F" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <ContentControl x:Name="HeaderBottomSelected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="{TemplateBinding Foreground}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualBottomSelected" Margin="1,0,1,0" Background="#8CFFFFFF" CornerRadius="0,0,3,3" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateBottomUnselected" Margin="2,0,2,0" Visibility="Collapsed">
                            <Grid Margin="1,0,1,0">
                                <Border x:Name="BottomUnselectedOver" Margin="0,0,0,1" BorderBrush="#FFDDEFFF" BorderThickness="1,0,1,1" CornerRadius=".5,.5,2.21,2.21" Opacity="0">
                                    <Border.Background>
                                        <RadialGradientBrush GradientOrigin="0.503,1.06">
                                            <RadialGradientBrush.RelativeTransform>
                                                <TransformGroup>
                                                    <ScaleTransform CenterX="0.5" CenterY="0.5" ScaleX="2.06" ScaleY="2.418"/>
                                                    <SkewTransform CenterX="0.5" CenterY="0.5"/>
                                                    <RotateTransform CenterX="0.5" CenterY="0.5"/>
                                                    <TranslateTransform X="0" Y="-0.339"/>
                                                </TransformGroup>
                                            </RadialGradientBrush.RelativeTransform>
                                            <GradientStop Color="#00FFFFFF" Offset="0.362"/>
                                            <GradientStop Color="#AEE8E6E6" Offset="0.496"/>
                                            <GradientStop Color="#F2E7D39C" Offset="0.629"/>
                                        </RadialGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BottomUnselectedBorderOver" Margin="-1,0,-1,0" BorderThickness="1,0,1,1" BorderBrush="#FF9FBCF0" CornerRadius="0,0,3.5,3.5" Opacity="0"/>
                                <ContentControl x:Name="HeaderBottomUnselected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="#FFFFFFFF" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualBottomUnSelected" Margin="1,0,1,0" Background="#8CFFFFFF" CornerRadius="0,0,3,3" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateLeftSelected" Margin="0,2,0,2" Canvas.ZIndex="1" Visibility="Collapsed">
                            <Grid Margin="0,1,0,1">
                                <Border x:Name="BackgroundLeft" BorderBrush="#FFF3F8FF" BorderThickness="0,2,0,2" CornerRadius="3,0,0,3">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="1,0.5" StartPoint="-0.5,0.5">
                                            <GradientStop Color="#FFEFF6FE" Offset="0"/>
                                            <GradientStop Color="#FFE0EAF6" Offset="0.384"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BorderLeft" BorderThickness="0,2,0,2" CornerRadius="3,0,0,3">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="1,0.5" StartPoint="-0.5,0.5">
                                            <GradientStop Color="#FFECF9FA" Offset="0"/>
                                            <GradientStop Color="#FFB4E0F4" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="HighlightLeft" Margin="0,2,0,2" BorderThickness="3,1,0,1" CornerRadius="1.25,0,0,1.25">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="1,0.5" StartPoint="-0.5,0.5">
                                            <GradientStop Color="#FFF3F8FF" Offset="0"/>
                                            <GradientStop Color="#D8ECF8FC" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BorderLeft2" Margin="0,-1,0,-1" BorderBrush="#FF9ABBE6" BorderThickness="1,1,0,1" CornerRadius="3,0,0,3" IsHitTestVisible="false"/>
                                <Border x:Name="FocusVisualLeft" Margin="0,-1,0,-1" BorderThickness="2,3,0,3" CornerRadius="3,0,0,3" Visibility="Collapsed">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="1,0.5" StartPoint="-0.5,0.5">
                                            <GradientStop Color="#99F7C53B" Offset="0"/>
                                            <GradientStop Color="#99F2B93F" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <ContentControl x:Name="HeaderLeftSelected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="{TemplateBinding Foreground}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualLeftSelected" Margin="0,1,0,1" Background="#8CFFFFFF" CornerRadius="3,0,0,3" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateLeftUnselected" Margin="0,2,0,2" Visibility="Collapsed">
                            <Grid Margin="0,1,0,1">
                                <Border x:Name="LeftUnselectedOver" BorderBrush="#FFDDEFFF" BorderThickness="1,1,0,1" CornerRadius="2.21,.5,.5,2.21" Opacity="0">
                                    <Border.Background>
                                        <RadialGradientBrush GradientOrigin="0.949,0.503">
                                            <RadialGradientBrush.RelativeTransform>
                                                <TransformGroup>
                                                    <ScaleTransform CenterX="0.5" CenterY="0.5" ScaleX="2.06" ScaleY="2.418"/>
                                                    <SkewTransform CenterX="0.5" CenterY="0.5"/>
                                                    <RotateTransform CenterX="0.5" CenterY="0.5" Angle="-180"/>
                                                    <TranslateTransform X="0.193" Y="0"/>
                                                </TransformGroup>
                                            </RadialGradientBrush.RelativeTransform>
                                            <GradientStop Color="#00FFFFFF" Offset="0.362"/>
                                            <GradientStop Color="#AEE8E6E6" Offset="0.496"/>
                                            <GradientStop Color="#F2E7D39C" Offset="0.629"/>
                                        </RadialGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="LeftUnselectedBorderOver" Margin="-1,-1,0.5,-1" BorderBrush="#FF9FBCF0" BorderThickness="1,1,0,1" CornerRadius="3.5,0,0,3.5" Opacity="0"/>
                                <ContentControl x:Name="HeaderLeftUnselected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="#FFFFFFFF" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualLeftUnSelected" Margin="0,1,0,1" Background="#8CFFFFFF" CornerRadius="3,0,0,3" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateRightSelected" Margin="0,2,0,2" Canvas.ZIndex="1" Visibility="Collapsed">
                            <Grid Margin="0,1,0,1">
                                <Border x:Name="BackgroundRight" BorderBrush="#FFF3F8FF" BorderThickness="0,2,0,2" CornerRadius="0,3,3,0">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="-0.5,0.5" StartPoint="1,0.5">
                                            <GradientStop Color="#FFEFF6FE" Offset="0"/>
                                            <GradientStop Color="#FFE0EAF6" Offset="0.384"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BorderRight" BorderThickness="0,2,0,2" CornerRadius="0,3,3,0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="-0.5,0.5" StartPoint="1,0.5">
                                            <GradientStop Color="#FFECF9FA" Offset="0"/>
                                            <GradientStop Color="#FFB4E0F4" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="HighlightRight" Margin="0,2,0,2" BorderThickness="0,1,3,1" CornerRadius="0,1.25,1.25,0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="-0.5,0.5" StartPoint="1,0.5">
                                            <GradientStop Color="#FFF3F8FF" Offset="0"/>
                                            <GradientStop Color="#D8ECF8FC" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BorderRight2" BorderBrush="#FF9ABBE6" BorderThickness="0,1,1,1" CornerRadius="0,3,3,0" IsHitTestVisible="false"/>
                                <Border x:Name="FocusVisualRight" Margin="0,-1,0,-1" BorderThickness="0,3,2,3" CornerRadius="0,3,3,0" Visibility="Collapsed">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="-0.5,0.5" StartPoint="1,0.5">
                                            <GradientStop Color="#99F7C53B" Offset="0"/>
                                            <GradientStop Color="#99F2B93F" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <ContentControl x:Name="HeaderRightSelected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="{TemplateBinding Foreground}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualRightSelected" Margin="0,1,0,1" Background="#8CFFFFFF" CornerRadius="0,3,3,0" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                        <Grid x:Name="TemplateRightUnselected" Margin="0,2,0,2" Visibility="Collapsed">
                            <Grid Margin="0,1,0,1">
                                <Border x:Name="RightUnselectedOver" BorderBrush="#FFDDEFFF" BorderThickness="0,1,1,1" CornerRadius=".5,2.21,2.21,.5" Opacity="0">
                                    <Border.Background>
                                        <RadialGradientBrush GradientOrigin="0.949,0.503">
                                            <RadialGradientBrush.RelativeTransform>
                                                <TransformGroup>
                                                    <ScaleTransform CenterX="0.5" CenterY="0.5" ScaleX="2.06" ScaleY="2.418"/>
                                                    <SkewTransform CenterX="0.5" CenterY="0.5"/>
                                                    <RotateTransform CenterX="0.5" CenterY="0.5"/>
                                                    <TranslateTransform X="-0.193" Y="0"/>
                                                </TransformGroup>
                                            </RadialGradientBrush.RelativeTransform>
                                            <GradientStop Color="#00FFFFFF" Offset="0.362"/>
                                            <GradientStop Color="#AEE8E6E6" Offset="0.496"/>
                                            <GradientStop Color="#F2E7D39C" Offset="0.629"/>
                                        </RadialGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="RightUnselectedBorderOver" Margin="0,-1,-1,-1" BorderBrush="#FF9FBCF0" BorderThickness="0,1,1,1" CornerRadius="0,3.5,3.5,0" Opacity="0"/>
                                <ContentControl x:Name="HeaderRightUnselected" Margin="{TemplateBinding Padding}" FontSize="{TemplateBinding FontSize}" Foreground="#FFFFFFFF" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                            </Grid>
                            <Border x:Name="DisabledVisualRightUnSelected" Margin="0,1,0,1" Background="#8CFFFFFF" CornerRadius="0,3,3,0" IsHitTestVisible="false" Visibility="Collapsed"/>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:TabControl">
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="Padding" Value="5"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:TabControl">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualTop" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualBottom" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualLeft" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualRight" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid x:Name="TemplateTop" Visibility="Collapsed">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border Margin="0,0,0,3" Background="#FFBFDBFF" Grid.RowSpan="2" CornerRadius="2,2,0,0"/>
                            <controlsPrimitives:TabPanel x:Name="TabPanelTop" Margin="2,2,2,-1" Canvas.ZIndex="1"/>
                            <Border Grid.Row="1" MinHeight="10" MinWidth="10" Background="#FFE0EAF6" BorderBrush="#FF9ABBE6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3,3,1,1">
                                <ContentPresenter x:Name="ContentTop" Margin="{TemplateBinding Padding}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}"/>
                            </Border>
                            <Border x:Name="DisabledVisualTop" Grid.Row="1" Grid.RowSpan="2" Background="#8CFFFFFF" CornerRadius="3,3,1,1" Canvas.ZIndex="1" IsHitTestVisible="False" Opacity="0"/>
                        </Grid>
                        <Grid x:Name="TemplateBottom" Visibility="Collapsed">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="*"/>
                                <RowDefinition Height="Auto"/>
                            </Grid.RowDefinitions>
                            <Border Margin="0,3,0,0" Background="#FFBFDBFF" Grid.RowSpan="2" CornerRadius="0,0,2,2"/>
                            <controlsPrimitives:TabPanel x:Name="TabPanelBottom" Margin="2,-1,2,2" Grid.Row="1" Canvas.ZIndex="1"/>
                            <Border MinHeight="10" MinWidth="10" Background="#FFE0EAF6" BorderBrush="#FF9ABBE6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1,1,3,3">
                                <ContentPresenter x:Name="ContentBottom" Margin="{TemplateBinding Padding}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}"/>
                            </Border>
                            <Border x:Name="DisabledVisualBottom" Background="#8CFFFFFF" CornerRadius="1,1,3,3" Canvas.ZIndex="1" IsHitTestVisible="False" Opacity="0"/>
                        </Grid>
                        <Grid x:Name="TemplateLeft" Visibility="Collapsed">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto"/>
                                <ColumnDefinition Width="*"/>
                            </Grid.ColumnDefinitions>
                            <Border Margin="0,0,3,0" Background="#FFBFDBFF" Grid.ColumnSpan="2" CornerRadius="2,0,0,2"/>
                            <controlsPrimitives:TabPanel x:Name="TabPanelLeft" Margin="2,2,-1,2" Canvas.ZIndex="1"/>
                            <Border MinHeight="10" MinWidth="10" Grid.Column="1" Background="#FFE0EAF6" BorderBrush="#FF9ABBE6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3,1,1,3">
                                <ContentPresenter x:Name="ContentLeft" Margin="{TemplateBinding Padding}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}"/>
                            </Border>
                            <Border x:Name="DisabledVisualLeft" Grid.Column="1" Background="#8CFFFFFF" CornerRadius="3,1,1,3" Canvas.ZIndex="1" IsHitTestVisible="False" Opacity="0"/>
                        </Grid>
                        <Grid x:Name="TemplateRight" Visibility="Collapsed">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*"/>
                                <ColumnDefinition Width="Auto"/>
                            </Grid.ColumnDefinitions>
                            <Border Margin="3,0,0,0" Background="#FFBFDBFF" Grid.ColumnSpan="2" CornerRadius="1,2,2,1"/>
                            <controlsPrimitives:TabPanel x:Name="TabPanelRight" Margin="-1,2,2,2" Grid.Column="1" Canvas.ZIndex="1"/>
                            <Border MinHeight="10" MinWidth="10" Background="#FFE0EAF6" BorderBrush="#FF9ABBE6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1,3,3,1">
                                <ContentPresenter x:Name="ContentRight" Margin="{TemplateBinding Padding}" Cursor="{TemplateBinding Cursor}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}"/>
                            </Border>
                            <Border x:Name="DisabledVisualRight" Background="#8CFFFFFF" CornerRadius="1,3,3,1" Canvas.ZIndex="1" IsHitTestVisible="False" Opacity="0"/>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="PasswordBox">
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="SelectionBackground" Value="#FF88C3FF"/>
        <Setter Property="SelectionForeground" Value="#FF000000"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="Padding" Value="4"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFABAEB3"/>
                    <GradientStop Color="#FFE2E8EE" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="PasswordBox">
                    <Grid x:Name="RootElement">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="ReadOnly"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Disabled"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal">
                                    <Storyboard/>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Over" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Over_Border" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ReadOnly">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ReadOnlyVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>

                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="BorderBase" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75"/>
                        <Border x:Name="Over" BorderBrush="#FFB1703C" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" Opacity="0"/>
                        <Border x:Name="Over_Border" Margin="-1" BorderBrush="#BFFBD261" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3.75" IsHitTestVisible="False" Opacity="0"/>
                        <Border Margin="{TemplateBinding Padding}" x:Name="ContentElement" />
                        <Border x:Name="DisabledVisualElement" Background="#00FFFFFF" BorderBrush="#59C0C0C0" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" IsHitTestVisible="False" Visibility="Collapsed"/>
                        <Border x:Name="ReadOnlyVisualElement" Background="#66FFFFFF" CornerRadius="2.75" Visibility="Collapsed"/>
                        <Border x:Name="FocusVisualElement" BorderBrush="#FFB1703C" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" IsHitTestVisible="False" Visibility="Collapsed"/>
                        <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                    <ToolTip.Triggers>
                                        <EventTrigger RoutedEvent="Canvas.Loaded">
                                            <BeginStoryboard>
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                        <DiscreteObjectKeyFrame KeyTime="0">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <system:Boolean>true</system:Boolean>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </BeginStoryboard>
                                        </EventTrigger>
                                    </ToolTip.Triggers>
                                </ToolTip>
                            </ToolTipService.ToolTip>
                            <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                            </Grid>
                        </Border>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="TextBox">
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="SelectionBackground" Value="#FF88C3FF"/>
        <Setter Property="SelectionForeground" Value="#FF000000"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="Padding" Value="4"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFABAEB3"/>
                    <GradientStop Color="#FFE2E8EE" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="TextBox">
                    <Grid x:Name="RootElement">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="ReadOnly"/>
                                    <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Disabled"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal">
                                    <Storyboard/>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Over" Storyboard.TargetProperty="Opacity" To="1"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Over_Border" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ReadOnly">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ReadOnlyVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid"/>
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ValidationErrorElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsOpen">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <system:Boolean>True</system:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>

                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="BorderBase" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75"/>
                        <Border x:Name="Over" BorderBrush="#FFB1703C" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" Opacity="0"/>
                        <Border x:Name="Over_Border" Margin="-1" BorderBrush="#BFFBD261" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3.75" IsHitTestVisible="False" Opacity="0"/>
                        <ScrollViewer x:Name="ContentElement" Padding="{TemplateBinding Padding}" BorderThickness="0" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="False"/>
                        <Border x:Name="DisabledVisualElement" Background="#A5FFFFFF" BorderBrush="#59C0C0C0" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" IsHitTestVisible="False" Visibility="Collapsed"/>
                        <Border x:Name="ReadOnlyVisualElement" Background="#66FFFFFF" CornerRadius="2.75" Visibility="Collapsed"/>
                        <Border x:Name="FocusVisualElement" BorderBrush="#FFB1703C" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2.75" IsHitTestVisible="False" Visibility="Collapsed"/>
                        <Border x:Name="ValidationErrorElement" Visibility="Collapsed" BorderBrush="#FFDB000C" BorderThickness="1" CornerRadius="7">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}" Template="{StaticResource ValidationToolTipTemplate}" Placement="Right" PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}">
                                    <ToolTip.Triggers>
                                        <EventTrigger RoutedEvent="Canvas.Loaded">
                                            <BeginStoryboard>
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="validationTooltip" Storyboard.TargetProperty="IsHitTestVisible">
                                                        <DiscreteObjectKeyFrame KeyTime="0">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <system:Boolean>true</system:Boolean>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </BeginStoryboard>
                                        </EventTrigger>
                                    </ToolTip.Triggers>
                                </ToolTip>
                            </ToolTipService.ToolTip>
                            <Grid Height="12" HorizontalAlignment="Right" Margin="1,-4,-4,0" VerticalAlignment="Top" Width="12" Background="Transparent">
                                <Path Fill="#FFDC000C" Margin="1,3,0,0" Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"/>
                                <Path Fill="#ffffff" Margin="1,3,0,0" Data="M 0,0 L2,0 L 8,6 L8,8"/>
                            </Grid>
                        </Border>

                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="input:AutoCompleteBox">
        <Setter Property="FilterMode" Value="StartsWith"/>
        <Setter Property="Background" Value="#FFFFFFFF"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Padding" Value="4"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFABAEB3"/>
                    <GradientStop Color="#FFE2E8EE" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="input:AutoCompleteBox">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="PopupStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.1" To="PopupOpened"/>
                                    <vsm:VisualTransition GeneratedDuration="0:0:0.2" To="PopupClosed"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="PopupOpened">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="PopupBorder" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="PopupClosed"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <TextBox x:Name="Text" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" Foreground="{TemplateBinding Foreground}" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" Padding="{TemplateBinding Padding}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" IsTabStop="True"/>
                        <Popup x:Name="Popup">
                            <Border x:Name="PopupBorder" Opacity="0">
                                <ListBox x:Name="Selector" Foreground="{TemplateBinding Foreground}" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"/>
                            </Border>
                        </Popup>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:TreeViewItem">
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="Padding" Value="5,3,15,3"/>
        <Setter Property="Cursor" Value="Arrow"/>
        <Setter Property="IsTabStop" Value="True"/>
        <Setter Property="TabNavigation" Value="Once"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:TreeViewItem">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="Header" Storyboard.TargetProperty="(UIElement.Foreground).(SolidColorBrush.Color)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="#FF999999"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="SelectionStates">
                                <vsm:VisualState x:Name="Unselected"/>
                                <vsm:VisualState x:Name="Selected">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="select_gradient" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="SelectedInactive">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="inactive" Storyboard.TargetProperty="Opacity" To=".2"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="HasItemsStates">
                                <vsm:VisualState x:Name="HasItems"/>
                                <vsm:VisualState x:Name="NoItems">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ExpansionStates">
                                <vsm:VisualState x:Name="Collapsed"/>
                                <vsm:VisualState x:Name="Expanded">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ItemsHost" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="*"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="15"/>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="*"/>
                        </Grid.ColumnDefinitions>
                        <ToggleButton x:Name="ExpanderButton" IsTabStop="False">
                            <ToggleButton.Template>
                                <ControlTemplate TargetType="ToggleButton">
                                    <Grid x:Name="Root">
                                        <vsm:VisualStateManager.VisualStateGroups>
                                            <vsm:VisualStateGroup x:Name="CommonStates">
                                                <vsm:VisualState x:Name="Normal"/>
                                                <vsm:VisualState x:Name="MouseOver">
                                                    <Storyboard>
                                                        <ColorAnimation Duration="0" Storyboard.TargetName="UncheckedVisual" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" To="#FFFFCB66"/>
                                                        <ColorAnimation Duration="0" Storyboard.TargetName="UncheckedVisual" Storyboard.TargetProperty="(Shape.Stroke).(SolidColorBrush.Color)" To="#FFFFCB66"/>
                                                        <ColorAnimation Duration="0" Storyboard.TargetName="CheckedVisual" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)" To="#FFFFCB66"/>
                                                        <ColorAnimation Duration="0" Storyboard.TargetName="CheckedVisual" Storyboard.TargetProperty="(Shape.Stroke).(SolidColorBrush.Color)" To="#FFFFCB66"/>
                                                    </Storyboard>
                                                </vsm:VisualState>
                                                <vsm:VisualState x:Name="Disabled">
                                                    <Storyboard>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity" To=".7"/>
                                                    </Storyboard>
                                                </vsm:VisualState>
                                            </vsm:VisualStateGroup>
                                            <vsm:VisualStateGroup x:Name="CheckStates">
                                                <vsm:VisualState x:Name="Unchecked"/>
                                                <vsm:VisualState x:Name="Checked">
                                                    <Storyboard>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="UncheckedVisual" Storyboard.TargetProperty="Opacity" To="0"/>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CheckedVisual" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    </Storyboard>
                                                </vsm:VisualState>
                                            </vsm:VisualStateGroup>
                                        </vsm:VisualStateManager.VisualStateGroups>
                                        <Grid HorizontalAlignment="Right" Margin="2,2,5,2">
                                            <Path x:Name="UncheckedVisual" Height="9" Width="6" HorizontalAlignment="Right" VerticalAlignment="Center" Fill="#FF9EC6FB" Stroke="#FF9EC6FB" StrokeLineJoin="Miter" Data="M 0,0 L 0,9 L 5,4.5 Z"/>
                                            <Path x:Name="CheckedVisual" Height="6" Width="6" HorizontalAlignment="Right" VerticalAlignment="Center" Fill="#FFE56E17" Stroke="#FFE56E17" StrokeLineJoin="Miter" Opacity="0" Data="M 6,0 L 6,6 L 0,6 Z"/>
                                        </Grid>
                                    </Grid>
                                </ControlTemplate>
                            </ToggleButton.Template>
                        </ToggleButton>
                        <Rectangle x:Name="select_gradient" Grid.Column="1" StrokeThickness="1" RadiusX="1" RadiusY="1" Opacity="0" IsHitTestVisible="False">
                            <Rectangle.Fill>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF636363" Offset="0"/>
                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Fill>
                            <Rectangle.Stroke>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                </LinearGradientBrush>
                            </Rectangle.Stroke>
                        </Rectangle>
                        <Rectangle x:Name="inactive" Grid.Column="1" Fill="#FF999999" Stroke="#FF333333" StrokeThickness="1" RadiusX="2" RadiusY="2" Opacity="0" IsHitTestVisible="False"/>
                        <Button x:Name="Header" Grid.Column="1" Foreground="{TemplateBinding Foreground}" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" Padding="{TemplateBinding Padding}" Content="{TemplateBinding Header}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" ContentTemplate="{TemplateBinding HeaderTemplate}" Cursor="{TemplateBinding Cursor}" ClickMode="Hover" IsTabStop="False">
                            <Button.Template>
                                <ControlTemplate TargetType="Button">
                                    <Grid>
                                        <vsm:VisualStateManager.VisualStateGroups>
                                            <vsm:VisualStateGroup x:Name="CommonStates">
                                                <vsm:VisualState x:Name="Normal"/>
                                                <vsm:VisualState x:Name="Pressed">
                                                    <Storyboard>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="hover_gradient" Storyboard.TargetProperty="Opacity" To="0.85"/>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="highlight" Storyboard.TargetProperty="Opacity" To="0.65"/>
                                                    </Storyboard>
                                                </vsm:VisualState>
                                                <vsm:VisualState x:Name="Disabled">
                                                    <Storyboard>
                                                        <DoubleAnimation Duration="0" Storyboard.TargetName="content" Storyboard.TargetProperty="Opacity" To=".55"/>
                                                    </Storyboard>
                                                </vsm:VisualState>
                                            </vsm:VisualStateGroup>
                                        </vsm:VisualStateManager.VisualStateGroups>
                                        <Rectangle x:Name="hover_gradient" Stroke="#FFE99A65" StrokeThickness="1" RadiusX="1" RadiusY="1" Opacity="0" IsHitTestVisible="False">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="highlight" Margin="1" StrokeThickness="1" RadiusX="0.5" RadiusY="0.5" Opacity="0" IsHitTestVisible="False">
                                            <Rectangle.Stroke>
                                                <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                    <GradientStop Color="#FFFFECB4"/>
                                                    <GradientStop Color="#FFFFFFFF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Stroke>
                                        </Rectangle>
                                        <ContentPresenter x:Name="content" Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" HorizontalAlignment="Left" VerticalAlignment="Center" Cursor="{TemplateBinding Cursor}"/>
                                    </Grid>
                                </ControlTemplate>
                            </Button.Template>
                        </Button>
                        <ItemsPresenter x:Name="ItemsHost" Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="1" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controls:TreeView">
        <Setter Property="Background" Value="{StaticResource ControlBackgroundBrush}"/>
        <Setter Property="Foreground" Value="Black"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Padding" Value="4"/>
        <Setter Property="Cursor" Value="Arrow"/>
        <Setter Property="IsTabStop" Value="True"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:TreeView">
                    <Grid x:Name="Root">
                        <Border x:Name="Border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1">
                            <ScrollViewer x:Name="ScrollViewer" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto">
                                <ItemsPresenter x:Name="TreeItems"/>
                            </ScrollViewer>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="controlsToolkit:Expander">
        <Setter Property="Foreground" Value="#FF15428B"/>
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="FontWeight" Value="Bold"/>
        <Setter Property="Padding" Value="6,0,4,0"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controlsToolkit:Expander">
                    <Grid>
                        <Grid.Resources>
                            <ControlTemplate x:Key="ExpanderDownHeaderTemplate" TargetType="ToggleButton">
                                <Grid Background="Transparent">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CheckStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Checked">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow2" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unchecked"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="border_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="Focus_Border" Storyboard.TargetProperty="Visibility">
                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                    </ObjectAnimationUsingKeyFrames>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_focus" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid Background="Transparent">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="*"/>
                                            <ColumnDefinition Width="20"/>
                                        </Grid.ColumnDefinitions>
                                        <Border x:Name="border_fill" Grid.ColumnSpan="2">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.293,0.43" StartPoint="0.742,0.43">
                                                    <GradientStop Color="#FFD6E8FF"/>
                                                    <GradientStop Color="#FFE2EEFF" Offset="0.539"/>
                                                    <GradientStop Color="#FFD6E8FF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="border_inner" Margin="0,0,0,1" Grid.ColumnSpan="2" BorderBrush="#FFFFFFFF" BorderThickness="1,1,0,0"/>
                                        <Border x:Name="border_bottom" Grid.ColumnSpan="2" BorderBrush="#FFADD1FF" BorderThickness="0,0,0,1"/>
                                        <Border x:Name="border_over" Margin="1" Grid.ColumnSpan="2" Opacity="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.667,0.528" StartPoint="0.266,0.528">
                                                    <GradientStop Color="#FFE3EFFF" Offset="0"/>
                                                    <GradientStop Color="#FFFFFFFF" Offset="0.548"/>
                                                    <GradientStop Color="#FFE3EFFF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Rectangle x:Name="arrow_over" Margin="0,1,1,1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="arrow_focus" Margin="0,1,1,1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path x:Name="arrow2" Margin="0,0,6,6" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Right" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <Path x:Name="arrow" Margin="0,2,6,0" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Right" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <ContentPresenter x:Name="header" Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" VerticalAlignment="Center" IsHitTestVisible="false"/>
                                        <Border x:Name="Focus_Border" Margin="-1,-1,-1,0" Grid.ColumnSpan="2" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="false" Visibility="Collapsed" Canvas.ZIndex="1"/>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="ExpanderUpHeaderTemplate" TargetType="ToggleButton">
                                <Grid Background="Transparent">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CheckStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Checked">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow2" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unchecked"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="border_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="Focus_Border" Storyboard.TargetProperty="Visibility">
                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                    </ObjectAnimationUsingKeyFrames>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_focus" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid Background="Transparent">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="*"/>
                                            <ColumnDefinition Width="20"/>
                                        </Grid.ColumnDefinitions>
                                        <Border x:Name="border_fill" Grid.ColumnSpan="2">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.293,0.43" StartPoint="0.742,0.43">
                                                    <GradientStop Color="#FFD6E8FF"/>
                                                    <GradientStop Color="#FFE2EEFF" Offset="0.539"/>
                                                    <GradientStop Color="#FFD6E8FF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="border_inner" Margin="0,1,0,0" Grid.ColumnSpan="2" BorderBrush="#FFFFFFFF" BorderThickness="1,0,0,1"/>
                                        <Border x:Name="border_bottom" Grid.ColumnSpan="2" BorderBrush="#FFADD1FF" BorderThickness="0,1,0,0"/>
                                        <Border x:Name="border_over" Margin="1" Grid.ColumnSpan="2" Opacity="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.667,0.528" StartPoint="0.266,0.528">
                                                    <GradientStop Color="#FFE3EFFF" Offset="0"/>
                                                    <GradientStop Color="#FFFFFFFF" Offset="0.548"/>
                                                    <GradientStop Color="#FFE3EFFF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Rectangle x:Name="arrow_over" Margin="0,1,1,1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,0" StartPoint="0,1">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="arrow_focus" Margin="0,1,1,1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,0" StartPoint="0,1">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path x:Name="arrow2" Margin="0,4,6,0" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Right" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform ScaleY="-1"/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <Path x:Name="arrow" Margin="0,0,6,4" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Right" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform ScaleY="-1"/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <ContentPresenter x:Name="header" Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" VerticalAlignment="Center" IsHitTestVisible="false"/>
                                        <Border x:Name="Focus_Border" Margin="-1,0,-1,-1" Grid.ColumnSpan="2" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="false" Visibility="Collapsed" Canvas.ZIndex="1"/>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="ExpanderLeftHeaderTemplate" TargetType="ToggleButton">
                                <Grid Background="Transparent">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CheckStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Checked">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow2" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unchecked"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="border_over" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="Focus_Border" Storyboard.TargetProperty="Visibility">
                                                        <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                    </ObjectAnimationUsingKeyFrames>
                                                    <DoubleAnimation Duration="00:00:00.0010000" Storyboard.TargetName="arrow_focus" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid Background="Transparent">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="20"/>
                                            <ColumnDefinition Width="*"/>
                                        </Grid.ColumnDefinitions>
                                        <Border x:Name="border_fill" Grid.ColumnSpan="2">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.293,0.43" StartPoint="0.742,0.43">
                                                    <GradientStop Color="#FFD6E8FF"/>
                                                    <GradientStop Color="#FFE2EEFF" Offset="0.539"/>
                                                    <GradientStop Color="#FFD6E8FF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="border_inner" Margin="0,0,0,1" Grid.ColumnSpan="2" BorderBrush="#FFFFFFFF" BorderThickness="0,1,1,0"/>
                                        <Border x:Name="border_bottom" Grid.ColumnSpan="2" BorderBrush="#FFADD1FF" BorderThickness="0,0,0,1"/>
                                        <Border x:Name="border_over" Margin="1" Grid.ColumnSpan="2" Opacity="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.667,0.528" StartPoint="0.266,0.528">
                                                    <GradientStop Color="#FFE3EFFF" Offset="0"/>
                                                    <GradientStop Color="#FFFFFFFF" Offset="0.548"/>
                                                    <GradientStop Color="#FFE3EFFF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Rectangle x:Name="arrow_over" Margin="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="arrow_focus" Margin="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path x:Name="arrow2" Margin="3,0,0,0" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Left" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform Angle="90"/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <Path x:Name="arrow" Margin="7,0,0,0" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Left" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform Angle="90"/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <ContentPresenter x:Name="header" Margin="{TemplateBinding Padding}" Grid.Column="1" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" VerticalAlignment="Center" IsHitTestVisible="false"/>
                                        <Border x:Name="Focus_Border" Margin="0,-1,-1,-1" Grid.ColumnSpan="2" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="false" Visibility="Collapsed" Canvas.ZIndex="1"/>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="ExpanderRightHeaderTemplate" TargetType="ToggleButton">
                                <Grid Background="Transparent">
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CheckStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Checked">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow2" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unchecked"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow_over" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="border_over" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed"/>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="arrow_focus" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                        <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                                                    </DoubleAnimationUsingKeyFrames>
                                                    <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="Focus_Border" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                        <DiscreteObjectKeyFrame KeyTime="00:00:00">
                                                            <DiscreteObjectKeyFrame.Value>
                                                                <Visibility>Visible</Visibility>
                                                            </DiscreteObjectKeyFrame.Value>
                                                        </DiscreteObjectKeyFrame>
                                                    </ObjectAnimationUsingKeyFrames>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Grid Background="Transparent">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="*"/>
                                            <ColumnDefinition Width="20"/>
                                        </Grid.ColumnDefinitions>
                                        <Border x:Name="border_fill" Grid.ColumnSpan="2">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.293,0.43" StartPoint="0.742,0.43">
                                                    <GradientStop Color="#FFD6E8FF"/>
                                                    <GradientStop Color="#FFE2EEFF" Offset="0.539"/>
                                                    <GradientStop Color="#FFD6E8FF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Border x:Name="border_inner" Margin="0,0,0,1" Grid.ColumnSpan="2" BorderBrush="#FFFFFFFF" BorderThickness="1,1,0,0"/>
                                        <Border x:Name="border_bottom" Grid.ColumnSpan="2" BorderBrush="#FFADD1FF" BorderThickness="0,0,0,1"/>
                                        <Border x:Name="border_over" Margin="1" Grid.ColumnSpan="2" Opacity="0">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.667,0.528" StartPoint="0.266,0.528">
                                                    <GradientStop Color="#FFE3EFFF" Offset="0"/>
                                                    <GradientStop Color="#FFFFFFFF" Offset="0.548"/>
                                                    <GradientStop Color="#FFE3EFFF" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                        </Border>
                                        <Rectangle x:Name="arrow_over" Margin="1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Rectangle x:Name="arrow_focus" Margin="1" Grid.Column="1" Width="20" Opacity="0">
                                            <Rectangle.Fill>
                                                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                    <GradientStop Color="#FFF8C76B" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Rectangle.Fill>
                                        </Rectangle>
                                        <Path x:Name="arrow2" Margin="3,0,0,0" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Left" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform Angle="-90"/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <Path x:Name="arrow" Margin="7,0,0,0" Grid.Column="1" Stroke="#FF567DB1" StrokeThickness="1.5" HorizontalAlignment="Left" VerticalAlignment="Center" Data="M 1,1.5 L 4.5,5 L 8,1.5" RenderTransformOrigin="0.5,0.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform Angle="-90"/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                        <ContentPresenter x:Name="header" Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" VerticalAlignment="Center" IsHitTestVisible="false"/>
                                        <Border x:Name="Focus_Border" Margin="-1,-1,0,-1" Grid.ColumnSpan="2" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="false" Visibility="Collapsed" Canvas.ZIndex="1"/>
                                    </Grid>
                                </Grid>
                            </ControlTemplate>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Opacity)" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard/>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ExpansionStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Collapsed"/>
                                <vsm:VisualState x:Name="Expanded">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ExpandDirectionStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="ExpandDown">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd1" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ExpandUp">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="Template">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderUpHeaderTemplate}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ExpandLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="Template">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderLeftHeaderTemplate}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <PointAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="Background" Storyboard.TargetProperty="(Border.Background).(LinearGradientBrush.StartPoint)">
                                            <SplinePointKeyFrame KeyTime="00:00:00" Value="1.204,0.5"/>
                                        </PointAnimationUsingKeyFrames>
                                        <PointAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="Background" Storyboard.TargetProperty="(Border.Background).(LinearGradientBrush.EndPoint)">
                                            <SplinePointKeyFrame KeyTime="00:00:00" Value="-0.056,0.5"/>
                                        </PointAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ExpandRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="Template">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ExpanderRightHeaderTemplate}"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="1" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd1" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="Background" BorderBrush="#FF6593CF" BorderThickness="1" Padding="0">
                            <Border.Background>
                                <LinearGradientBrush EndPoint="1.204,0.5" StartPoint="0.056,0.5">
                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                    <GradientStop Color="#FFD4D7DB" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.Background>
                            <Grid>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="Auto" x:Name="cd0"/>
                                    <ColumnDefinition Width="Auto" x:Name="cd1"/>
                                </Grid.ColumnDefinitions>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto" x:Name="rd0"/>
                                    <RowDefinition Height="Auto" x:Name="rd1"/>
                                </Grid.RowDefinitions>
                                <ToggleButton x:Name="ExpanderButton" Grid.Column="0" Grid.Row="0" MinHeight="20" Content="{TemplateBinding Header}" ContentTemplate="{TemplateBinding HeaderTemplate}" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" Padding="{TemplateBinding Padding}" Template="{StaticResource ExpanderDownHeaderTemplate}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" IsChecked="{TemplateBinding IsExpanded}"/>
                                <ContentControl x:Name="ExpandSite" Margin="1" Grid.Column="0" Grid.Row="1" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Visibility="Collapsed"/>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisualElement" IsHitTestVisible="false" Background="#A5FFFFFF" BorderBrush="#66FFFFFF" BorderThickness="1" Opacity="0"/>
                        <Border x:Name="FocusVisualElement" IsHitTestVisible="false" BorderBrush="#FFE99862" BorderThickness="1" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="inputToolkit:ButtonSpinner">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="inputToolkit:ButtonSpinner">
                    <Grid>
                        <Grid.Resources>
                            <ControlTemplate x:Key="IncreaseButton" TargetType="RepeatButton">
                                <Grid>
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="HoverBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPress" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#FFFFDA79"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="HoverBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused"/>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="BackgroundOver" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint=".7,0" StartPoint=".7,1">
                                                <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                <GradientStop Color="#F9FFF4C7" Offset="0.49"/>
                                                <GradientStop Color="#FFFFDA79" Offset="0.5"/>
                                                <GradientStop Color="#FFFFDA79" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="BackgroundPress" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                <GradientStop Color="#FFFFFFFF"/>
                                                <GradientStop Color="#FFFEE6BC" Offset="0.49"/>
                                                <GradientStop Color="#FFFFB63A" Offset="0.5"/>
                                                <GradientStop Color="#FFFEC566" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Border x:Name="HoverBorder" Margin="0,10,0,-10" BorderBrush="#7F9EBBDE" BorderThickness="1,0,1,1" Opacity="0"/>
                                    <Border x:Name="Highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,1,1,0" Opacity="0"/>
                                    <Rectangle x:Name="FocusVisualElement" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" IsHitTestVisible="false" Visibility="Collapsed"/>
                                    <Path Height="4" Width="8" Fill="#FF527DB5" Stretch="Uniform" Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z " HorizontalAlignment="Center" VerticalAlignment="Center"/>
                                </Grid>
                            </ControlTemplate>
                            <ControlTemplate x:Key="DecreaseButton" TargetType="RepeatButton">
                                <Grid>
                                    <vsm:VisualStateManager.VisualStateGroups>
                                        <vsm:VisualStateGroup x:Name="CommonStates">
                                            <vsm:VisualStateGroup.Transitions>
                                                <vsm:VisualTransition GeneratedDuration="0"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                                <vsm:VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                            </vsm:VisualStateGroup.Transitions>
                                            <vsm:VisualState x:Name="Normal"/>
                                            <vsm:VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="HoverBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="BackgroundPress" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="Opacity" To="1"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="Highlight" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#FFFFDA79"/>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="HoverBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </vsm:VisualState>
                                        </vsm:VisualStateGroup>
                                        <vsm:VisualStateGroup x:Name="FocusStates">
                                            <vsm:VisualState x:Name="Focused">
                                                <Storyboard/>
                                            </vsm:VisualState>
                                            <vsm:VisualState x:Name="Unfocused"/>
                                        </vsm:VisualStateGroup>
                                    </vsm:VisualStateManager.VisualStateGroups>
                                    <Rectangle x:Name="BackgroundOver" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint=".7,1" StartPoint=".7,0">
                                                <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                <GradientStop Color="#F9FFF4C7" Offset="0.49"/>
                                                <GradientStop Color="#FFFFDA79" Offset="0.5"/>
                                                <GradientStop Color="#FFFFDA79" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Rectangle x:Name="BackgroundPress" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" Opacity="0">
                                        <Rectangle.Fill>
                                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                <GradientStop Color="#FFFFFFFF"/>
                                                <GradientStop Color="#FFFEE6BC" Offset="0.49"/>
                                                <GradientStop Color="#FFFFB63A" Offset="0.5"/>
                                                <GradientStop Color="#FFFEC566" Offset="1"/>
                                            </LinearGradientBrush>
                                        </Rectangle.Fill>
                                    </Rectangle>
                                    <Border x:Name="HoverBorder" Margin="0,-10,0,10" BorderBrush="#7F9EBBDE" BorderThickness="1,1,1,0" Opacity="0"/>
                                    <Border x:Name="Highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" Opacity="0"/>
                                    <Rectangle x:Name="FocusVisualElement" Stroke="#FFDBCE98" StrokeThickness="1" RadiusX="0" RadiusY="0" IsHitTestVisible="false" Visibility="Collapsed"/>
                                    <Path Height="4" Width="8" Fill="#FF527DB5" Stretch="Uniform" Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z " HorizontalAlignment="Center" VerticalAlignment="Center"/>
                                </Grid>
                            </ControlTemplate>
                        </Grid.Resources>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Opacity)" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition/>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition/>
                            </Grid.RowDefinitions>
                            <RepeatButton x:Name="IncreaseButton" Template="{StaticResource IncreaseButton}" IsTabStop="False" ClickMode="Press"/>
                            <ContentPresenter Content="{TemplateBinding Content}" Grid.Row="1"/>
                            <RepeatButton x:Name="DecreaseButton" Grid.Row="2" Template="{StaticResource DecreaseButton}" IsTabStop="False" ClickMode="Press"/>
                        </Grid>
                        <Border x:Name="DisabledVisualElement" Background="#A5FFFFFF" IsHitTestVisible="false" Opacity="0"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style TargetType="inputToolkit:NumericUpDown">
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="Padding" Value="2,3,2,3"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="inputToolkit:NumericUpDown">
                    <Grid MinWidth="50" Height="22">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0"/>
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal"/>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Opacity)" To="1"/>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused"/>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border Background="#FFEAF2FB" BorderBrush="#FF9EBBDE" BorderThickness="1">
                            <Grid>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="15"/>
                                </Grid.ColumnDefinitions>
                                <inputToolkit:ButtonSpinner x:Name="Spinner" Grid.Column="1" IsTabStop="False"/>
                                <TextBox x:Name="Text" MinWidth="35" Background="#FFE8E8E8" SelectionBackground="#FF88C3FF" SelectionForeground="#FF000000" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" Padding="{TemplateBinding Padding}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalAlignment="Stretch" TextAlignment="Right" Text="{TemplateBinding Value}" TextWrapping="NoWrap" AcceptsReturn="False">
                                    <TextBox.Template>
                                        <ControlTemplate>
                                            <Grid>
                                                <vsm:VisualStateManager.VisualStateGroups>
                                                    <vsm:VisualStateGroup x:Name="CommonStates">
                                                        <vsm:VisualState x:Name="Normal"/>
                                                        <vsm:VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="MouseBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                                <ObjectAnimationUsingKeyFrames Duration="00:00:00.0010000" Storyboard.TargetName="SpinnerBorderOver" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="ReadOnly">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="ReadOnlyVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                    </vsm:VisualStateGroup>
                                                    <vsm:VisualStateGroup x:Name="FocusStates">
                                                        <vsm:VisualState x:Name="Focused">
                                                            <Storyboard>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="border" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" To="#FFFFFFFF"/>
                                                                <ObjectAnimationUsingKeyFrames Duration="00:00:00.0010000" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Duration="00:00:00.0010000" Storyboard.TargetName="SpinnerBorderPress" Storyboard.TargetProperty="(UIElement.Visibility)">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                        <vsm:VisualState x:Name="Unfocused">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity">
                                                                    <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </vsm:VisualState>
                                                    </vsm:VisualStateGroup>
                                                </vsm:VisualStateManager.VisualStateGroups>
                                                <Border x:Name="MouseBorder" Background="#FFFFFFFF" IsHitTestVisible="False" Opacity="0"/>
                                                <Border x:Name="ReadOnlyVisualElement" Background="#8CF7F7F7" IsHitTestVisible="False" Opacity="0"/>
                                                <Border x:Name="border" Background="Transparent">
                                                    <ScrollViewer x:Name="ContentElement" Padding="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" BorderThickness="0" IsTabStop="False"/>
                                                </Border>
                                                <Border x:Name="SpinnerBorderOver" Margin="0,0,-15,0" Width="15" BorderBrush="#7F9EBBDE" BorderThickness="1" HorizontalAlignment="Right" IsHitTestVisible="False" Visibility="Collapsed"/>
                                                <Border x:Name="SpinnerBorderPress" Margin="0,0,-15,0" Width="15" BorderBrush="#7F9EBBDE" BorderThickness="1" HorizontalAlignment="Right" IsHitTestVisible="False" Visibility="Collapsed"/>
                                                <Rectangle x:Name="DisabledVisualElement" Margin="-1,-1,-16,-1" Fill="#A5F7F7F7" Stroke="#0CFFFFFF" IsHitTestVisible="False" Opacity="0"/>
                                                <Border x:Name="FocusVisualElement" Margin="-2,-2,-17,-2" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="False" Visibility="Collapsed"/>
                                            </Grid>
                                        </ControlTemplate>
                                    </TextBox.Template>
                                </TextBox>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisualElement" Background="#A5FFFFFF" IsHitTestVisible="false" Opacity="0"/>
                        <Border x:Name="FocusVisualElement" Margin="-1" BorderBrush="#FFE99862" BorderThickness="1" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--Legend-->
    <Style TargetType="visualizationToolkit:Legend">
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}"/>
        <Setter Property="Background" Value="{StaticResource ControlBackgroundBrush}"/>
        <Setter Property="Foreground" Value="White"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="TitleStyle">
            <Setter.Value>
                <Style TargetType="visualizationToolkit:Title">
                    <Setter Property="Margin" Value="0,5,0,10"/>
                    <Setter Property="FontWeight" Value="Bold"/>
                    <Setter Property="HorizontalAlignment" Value="Center"/>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="visualizationToolkit:Legend">
                    <Border
                        Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}"

                        Padding="2">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition/>
                            </Grid.RowDefinitions>
                            <visualizationToolkit:Title
                                Grid.Row="0"
                                Content="{TemplateBinding Header}"
                                Style="{TemplateBinding TitleStyle}"/>
                            <ScrollViewer
                                Grid.Row="1"
                                VerticalScrollBarVisibility="Auto"
                                BorderThickness="0"
                                Padding="0"
                                IsTabStop="False">
                                <StackPanel Grid.Column="1" x:Name="LegendItemsArea" Margin="10,0,10,10" />
                            </ScrollViewer>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <!--Chart-->
    <Style TargetType="chartingToolkit:Chart">
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="Background" Value="{StaticResource ControlBackgroundBrush}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="visualizationToolkit:Title">
                    <ContentPresenter
                        Content="{TemplateBinding Content}"
                        ContentTemplate="{TemplateBinding ContentTemplate}"
                        Cursor="{TemplateBinding Cursor}"
                        Margin="{TemplateBinding Padding}"
                        HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                        VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="chartingToolkit:Chart">
                    <Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="10">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <visualizationToolkit:Title Style="{TemplateBinding TitleStyle}" Content="{TemplateBinding Title}"/>
                            <Grid Margin="0,15,0,15" Grid.Row="1">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="Auto"/>
                                </Grid.ColumnDefinitions>
                                <visualizationToolkit:Legend Margin="5,0,0,0" x:Name="Legend" Grid.Column="1" Header="{TemplateBinding LegendTitle}"/>
                                <chartingPrimitivesToolkit:EdgePanel x:Name="ChartArea" Style="{TemplateBinding ChartAreaStyle}">
                                    <Grid Canvas.ZIndex="-1" Style="{TemplateBinding PlotAreaStyle}" />
                                    <Border Canvas.ZIndex="10" BorderBrush="#FF919191" BorderThickness="1" />
                                </chartingPrimitivesToolkit:EdgePanel>
                            </Grid>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- AccordionButton  -->
    <Style TargetType="layoutPrimitivesToolkit:AccordionButton">
        <Setter Property="BorderThickness" Value="0"/>
        <Setter Property="Background" Value="White"/>
        <Setter Property="HorizontalAlignment" Value="Stretch"/>
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="IsTabStop" Value="True"/>
        <Setter Property="TabNavigation" Value="Once"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="layoutPrimitivesToolkit:AccordionButton">
                    <Grid Margin="{TemplateBinding Padding}" Background="Transparent">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="ExpandDirectionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="ExpandDown">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="cd1" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="-90"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandUp">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="cd1" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="90"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="rd1" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="LayoutTransform">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <TransformGroup>
                                                        <RotateTransform Angle="90"/>
                                                    </TransformGroup>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="0"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="icon" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="rd1" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Auto"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames BeginTime="0" Duration="0" Storyboard.TargetName="header" Storyboard.TargetProperty="LayoutTransform">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <TransformGroup>
                                                        <RotateTransform Angle="-90"/>
                                                    </TransformGroup>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="180"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ExpansionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Collapsed">
                                    <Storyboard>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="icon" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="0"/>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundNorm" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.75"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Expanded">
                                    <Storyboard>
                                        <DoubleAnimation BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="icon" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" To="90"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CheckStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="00:00:00"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Checked"/>
                                <VisualState x:Name="Unchecked"/>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                    <VisualTransition From="MouseOver" GeneratedDuration="00:00:00.1" To="Normal"/>
                                    <VisualTransition GeneratedDuration="00:00:00.1" To="MouseOver"/>
                                    <VisualTransition GeneratedDuration="00:00:00.1" To="Pressed"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <ColorAnimation BeginTime="0" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" To="#222"/>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.9"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.9"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ColorAnimation BeginTime="0" Storyboard.TargetName="arrow" Storyboard.TargetProperty="(Path.Stroke).(SolidColorBrush.Color)" To="#FF003366"/>
                                        <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="MouseOverBackground" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)">
                                            <SplineColorKeyFrame KeyTime="00:00:00" Value="#ff737573"/>
                                        </ColorAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Disabled">
                                    <Storyboard/>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.385"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unfocused"/>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border x:Name="background" Background="{TemplateBinding Background}" CornerRadius="1,1,1,1">
                            <Grid>
                                <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                            <GradientStop Color="#FF84B2D4"/>
                                            <GradientStop Color="#FFADC7DE" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                            <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                            <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                            <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                            <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                            <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BackgroundNorm_highlight" Margin="1" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65"/>
                                <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                            <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                            <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                            <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                            <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                            <GradientStop Color="#FFFFF48B" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                            <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                            <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgroundOver_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                            <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                            <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                            <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                            <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                            <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                            <GradientStop Color="#FFFFC472" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FF8E8165" Offset="0"/>
                                            <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgoundPressed_Highlight" Margin="1" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="ExpandedBackground" Height="Auto" Margin="0,0,0,0" VerticalAlignment="Stretch" Opacity="0" Background="#FFBADDE9" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1,1,1,1"/>
                                <Border x:Name="MouseOverBackground" Height="Auto" Margin="0,0,0,0" VerticalAlignment="Stretch" Opacity="0" Background="#FFBDBDBD" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1,1,1,1"/>
                                <Grid Background="Transparent">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition x:Name="cd0" Width="Auto"/>
                                        <ColumnDefinition x:Name="cd1" Width="Auto"/>
                                    </Grid.ColumnDefinitions>
                                    <Grid.RowDefinitions>
                                        <RowDefinition x:Name="rd0" Height="Auto"/>
                                        <RowDefinition x:Name="rd1" Height="Auto"/>
                                    </Grid.RowDefinitions>
                                    <Grid x:Name="icon" Height="19" HorizontalAlignment="Center" VerticalAlignment="Center" Width="19" RenderTransformOrigin="0.5,0.5" Grid.Column="0" Grid.Row="0">
                                        <Grid.RenderTransform>
                                            <TransformGroup>
                                                <ScaleTransform/>
                                                <SkewTransform/>
                                                <RotateTransform Angle="-90"/>
                                                <TranslateTransform/>
                                            </TransformGroup>
                                        </Grid.RenderTransform>
                                        <Path x:Name="arrow" Stroke="#E5042271" StrokeThickness="2" Height="Auto" HorizontalAlignment="Center" Margin="0,0,0,0" VerticalAlignment="Center" Width="Auto" RenderTransformOrigin="0.5,0.5" Data="M 1,1.5 L 4.5,5 L 8,1.5">
                                            <Path.RenderTransform>
                                                <TransformGroup>
                                                    <ScaleTransform/>
                                                    <SkewTransform/>
                                                    <RotateTransform/>
                                                    <TranslateTransform/>
                                                </TransformGroup>
                                            </Path.RenderTransform>
                                        </Path>
                                    </Grid>
                                    <layoutToolkit:LayoutTransformer x:Name="header" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="6,6,6,0" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" Grid.Column="0" Grid.Row="0" Grid.RowSpan="1"/>
                                </Grid>
                            </Grid>
                        </Border>
                        <Rectangle x:Name="FocusVisualElement" Stroke="#FF6DBDD1" StrokeThickness="1" RadiusX="1" RadiusY="1" IsHitTestVisible="false" Visibility="Collapsed"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- Accordion -->
    <Style TargetType="layoutToolkit:Accordion">
        <Setter Property="Foreground" Value="#FF000000"/>
        <Setter Property="BorderBrush" Value="#FFEAEAEA"/>
        <Setter Property="HorizontalAlignment" Value="Left"/>
        <Setter Property="VerticalAlignment" Value="Top"/>
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Top"/>
        <Setter Property="Cursor" Value="Arrow"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Padding" Value="0"/>
        <Setter Property="Margin" Value="0"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="TabNavigation" Value="Once"/>
        <Setter Property="ItemsPanel">
            <Setter.Value>
                <ItemsPanelTemplate>
                    <StackPanel VerticalAlignment="Top"/>
                </ItemsPanelTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="layoutToolkit:Accordion">
                    <Grid x:Name="Root">
                        <Border x:Name="Border" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}">
                            <ScrollViewer x:Name="ScrollViewer" HorizontalAlignment="Stretch" Margin="0" VerticalAlignment="Stretch" Background="{x:Null}" BorderBrush="Transparent" BorderThickness="0" Padding="0" HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden">
                                <ItemsPresenter/>
                            </ScrollViewer>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- AccordionItem  -->
    <Style TargetType="layoutToolkit:AccordionItem">
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush" Value="#FFECECEC"/>
        <Setter Property="Background" Value="White"/>
        <Setter Property="Margin" Value="0"/>
        <Setter Property="Padding" Value="0"/>
        <Setter Property="HorizontalAlignment" Value="Stretch"/>
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="HorizontalContentAlignment" Value="Left"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="IsTabStop" Value="False"/>
        <Setter Property="TabNavigation" Value="Once"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="layoutToolkit:AccordionItem">
                    <Grid HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}" Background="{TemplateBinding Background}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.Opacity)" To="1"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unfocused"/>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ExpansionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Collapsed">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(ExpandableContentControl.Percentage)">
                                            <SplineDoubleKeyFrame KeySpline="0.2,0,0,1" KeyTime="00:00:00.3" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Expanded">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(ExpandableContentControl.Percentage)">
                                            <SplineDoubleKeyFrame KeySpline="0.2,0,0,1" KeyTime="00:00:00.3" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="LockedStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Locked">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Unlocked">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ExpandDirectionStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="ExpandDown">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd1" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandUp">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandLeft">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.ColumnSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.ColumnSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.RowSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="2"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.RowSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="2"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd0" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="ExpandRight">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.ColumnSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.ColumnSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpanderButton" Storyboard.TargetProperty="(Grid.RowSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="2"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.RowSpan)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="2"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Row)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="0"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(Grid.Column)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="rd0" Storyboard.TargetProperty="Height">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="cd1" Storyboard.TargetProperty="Width">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="*"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border x:Name="Background" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1,1,1,1" Padding="{TemplateBinding Padding}">
                            <Grid>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition x:Name="cd0" Width="Auto"/>
                                    <ColumnDefinition x:Name="cd1" Width="Auto"/>
                                </Grid.ColumnDefinitions>
                                <Grid.RowDefinitions>
                                    <RowDefinition x:Name="rd0" Height="Auto"/>
                                    <RowDefinition x:Name="rd1" Height="Auto"/>
                                </Grid.RowDefinitions>
                                <layoutPrimitivesToolkit:AccordionButton x:Name="ExpanderButton" HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" IsTabStop="True" Padding="0,0,0,0" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Header}" ContentTemplate="{TemplateBinding HeaderTemplate}" Grid.Row="0" IsChecked="{TemplateBinding IsSelected}"/>
                                <layoutPrimitivesToolkit:ExpandableContentControl x:Name="ExpandSite" HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="Left" IsTabStop="False" VerticalContentAlignment="Top" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" Grid.Row="1" Percentage="0" RevealMode="{TemplateBinding ExpandDirection}"/>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisualElement" IsHitTestVisible="false" Opacity="0" Background="#A5FFFFFF" CornerRadius="3"/>
                        <Border x:Name="FocusVisualElement" IsHitTestVisible="false" Visibility="Collapsed" BorderThickness="1" CornerRadius="3">
                            <Border.BorderBrush>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFA3AEB9"/>
                                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                                    <GradientStop Color="#FF718597" Offset="0.375"/>
                                    <GradientStop Color="#FF617584" Offset="1"/>
                                </LinearGradientBrush>
                            </Border.BorderBrush>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--ChildWindow-->
    <Style TargetType="controls:ChildWindow">
        <Setter Property="IsTabStop" Value="false"/>
        <Setter Property="TabNavigation" Value="Cycle"/>
        <Setter Property="HorizontalAlignment" Value="Center"/>
        <Setter Property="VerticalAlignment" Value="Center"/>
        <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        <Setter Property="VerticalContentAlignment" Value="Stretch"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFA3AEB9" Offset="0"/>
                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                    <GradientStop Color="#FF718597" Offset="0.375"/>
                    <GradientStop Color="#FF617584" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="OverlayBrush" Value="#7F000000"/>
        <Setter Property="OverlayOpacity" Value="1"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:ChildWindow">
                    <Grid x:Name="Root">
                        <Grid.Resources>
                            <Style x:Key="CloseButtonStyle" TargetType="Button">
                                <Setter Property="Background" Value="#FF1F3B53"/>
                                <Setter Property="Foreground" Value="#FF000000"/>
                                <Setter Property="Padding" Value="3"/>
                                <Setter Property="BorderThickness" Value="1"/>
                                <Setter Property="BorderBrush">
                                    <Setter.Value>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFA3AEB9" Offset="0"/>
                                            <GradientStop Color="#FF8399A9" Offset="0.375"/>
                                            <GradientStop Color="#FF718597" Offset="0.375"/>
                                            <GradientStop Color="#FF617584" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="Button">
                                            <Grid x:Name="grid" Height="14" HorizontalAlignment="Center" VerticalAlignment="Center" Width="15" Background="#02FFFFFF">
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal"/>
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz2" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz1" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz0" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="X" Storyboard.TargetProperty="Opacity" To="0.95"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="X" Storyboard.TargetProperty="Opacity" To="0.85"/>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz2" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz1" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz0" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="X" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Path x:Name="X_Fuzz2" Fill="#14C51900" Stretch="Fill" Stroke="#14C51900" Height="8" HorizontalAlignment="Center" Margin="0,-1,0,0" VerticalAlignment="Center" Width="9" Opacity="1" RenderTransformOrigin="0.5,0.5" Visibility="Collapsed" Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z">
                                                    <Path.RenderTransform>
                                                        <TransformGroup>
                                                            <ScaleTransform ScaleX="1.3" ScaleY="1.3"/>
                                                        </TransformGroup>
                                                    </Path.RenderTransform>
                                                </Path>
                                                <Path x:Name="X_Fuzz1" Fill="#1EC51900" Stretch="Fill" Stroke="#1EC51900" Height="8" HorizontalAlignment="Center" Margin="0,-1,0,0" VerticalAlignment="Center" Width="9" Opacity="1" RenderTransformOrigin="0.5,0.5" Visibility="Collapsed" Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z">
                                                    <Path.RenderTransform>
                                                        <TransformGroup>
                                                            <ScaleTransform ScaleX="1.1" ScaleY="1.1"/>
                                                        </TransformGroup>
                                                    </Path.RenderTransform>
                                                </Path>
                                                <Path x:Name="X_Fuzz0" Fill="#FFC51900" Stretch="Fill" Stroke="#FFC51900" Height="8" HorizontalAlignment="Center" Margin="0,-1,0,0" VerticalAlignment="Center" Width="9" Opacity="1" Visibility="Collapsed" Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z"/>
                                                <Path x:Name="X" Fill="#FFFFFFFF" Stretch="Fill" Height="8" HorizontalAlignment="Center" Margin="0,-1,0,0" VerticalAlignment="Center" Width="9" Opacity="0.7" Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z">
                                                    <Path.Stroke>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FF313131" Offset="1"/>
                                                            <GradientStop Color="#FF8E9092" Offset="0"/>
                                                        </LinearGradientBrush>
                                                    </Path.Stroke>
                                                </Path>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                        </Grid.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="WindowStates">
                                <VisualState x:Name="Open">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="Overlay" Storyboard.TargetProperty="Opacity">
                                            <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.3" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="ContentRoot" Storyboard.TargetProperty="(RenderTransform).(Children)[0].ScaleX">
                                            <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.25" Value="0"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.4" Value="1"/>
                                            <SplineDoubleKeyFrame KeySpline="0,0,0.5,1" KeyTime="00:00:00.45" Value="1.05"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.55" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="ContentRoot" Storyboard.TargetProperty="(RenderTransform).(Children)[0].ScaleY">
                                            <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.25" Value="0"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.4" Value="1"/>
                                            <SplineDoubleKeyFrame KeySpline="0,0,0.5,1" KeyTime="00:00:00.45" Value="1.05"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.55" Value="1"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Closed">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="Overlay" Storyboard.TargetProperty="Opacity">
                                            <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.3" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="ContentRoot" Storyboard.TargetProperty="(RenderTransform).(Children)[0].ScaleX">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.2" Value="1"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.25" Value="1.05"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.45" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="0" Storyboard.TargetName="ContentRoot" Storyboard.TargetProperty="(RenderTransform).(Children)[0].ScaleY">
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.2" Value="1"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.25" Value="1.05"/>
                                            <SplineDoubleKeyFrame KeyTime="00:00:00.45" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid x:Name="Overlay" HorizontalAlignment="Stretch" Margin="0" VerticalAlignment="Top" Opacity="{TemplateBinding OverlayOpacity}" Background="{TemplateBinding OverlayBrush}"/>
                        <Grid x:Name="ContentRoot" Height="{TemplateBinding Height}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="{TemplateBinding VerticalAlignment}" Width="{TemplateBinding Width}" RenderTransformOrigin="0.5,0.5">
                            <Grid.RenderTransform>
                                <TransformGroup>
                                    <ScaleTransform/>
                                    <SkewTransform/>
                                    <RotateTransform/>
                                    <TranslateTransform/>
                                </TransformGroup>
                            </Grid.RenderTransform>
                            <Border HorizontalAlignment="Stretch" Margin="-1" VerticalAlignment="Stretch" Background="#14000000" BorderBrush="#14000000" BorderThickness="1" CornerRadius="2"/>
                            <Border HorizontalAlignment="Stretch" Margin="-2" VerticalAlignment="Stretch" Background="#0F000000" BorderBrush="#0F000000" BorderThickness="1" CornerRadius="2.25"/>
                            <Border HorizontalAlignment="Stretch" Margin="-3" VerticalAlignment="Stretch" Background="#0C000000" BorderBrush="#0C000000" BorderThickness="1" CornerRadius="2.5"/>
                            <Border HorizontalAlignment="Stretch" Margin="-4" VerticalAlignment="Stretch" Background="#0A000000" BorderBrush="#0A000000" BorderThickness="1" CornerRadius="2.75"/>
                            <Border Background="#FFFFFFFF" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                                <Border Margin="1" CornerRadius="1.5">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFE5E8EB" Offset="1"/>
                                            <GradientStop Color="#FFF6F8F9" Offset="0"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <Grid>
                                        <Grid.RowDefinitions>
                                            <RowDefinition Height="Auto"/>
                                            <RowDefinition/>
                                        </Grid.RowDefinitions>
                                        <Border x:Name="Chrome" Width="Auto" BorderBrush="#FFFFFFFF" BorderThickness="0,0,0,1">
                                            <Border.Background>
                                                <LinearGradientBrush EndPoint="0.5,0.528" StartPoint="0.5,0">
                                                    <GradientStop Color="#FFE5E8EB" Offset="1"/>
                                                    <GradientStop Color="#FFFEFEFE" Offset="0"/>
                                                </LinearGradientBrush>
                                            </Border.Background>
                                            <Grid Height="Auto" Width="Auto">
                                                <Grid.ColumnDefinitions>
                                                    <ColumnDefinition/>
                                                    <ColumnDefinition Width="30"/>
                                                </Grid.ColumnDefinitions>
                                                <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75" Grid.ColumnSpan="2" >
                                                    <Border.BorderBrush>
                                                        <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                                            <GradientStop Color="#FF84B2D4"/>
                                                            <GradientStop Color="#FFADC7DE" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.BorderBrush>
                                                    <Border.Background>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                            <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                                            <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                                            <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                                            <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                                            <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.Background>
                                                </Border>
                                                <Border x:Name="BackgroundNorm_highlight" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65" Grid.ColumnSpan="2" />
                                                <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0" Grid.ColumnSpan="2" >
                                                    <Border.Background>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                            <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                                            <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                                            <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                                            <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                                            <GradientStop Color="#FFFFF48B" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.Background>
                                                    <Border.BorderBrush>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                                            <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                                            <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.BorderBrush>
                                                </Border>
                                                <Border x:Name="BackgroundOver_Highlight" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0" Grid.ColumnSpan="2">
                                                    <Border.BorderBrush>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                                            <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.BorderBrush>
                                                </Border>
                                                <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0" Grid.ColumnSpan="2">
                                                    <Border.Background>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                            <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                                            <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                                            <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                                            <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                                            <GradientStop Color="#FFFFC472" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.Background>
                                                    <Border.BorderBrush>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FF8E8165" Offset="0"/>
                                                            <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.BorderBrush>
                                                </Border>
                                                <Border x:Name="BackgoundPressed_Highlight" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0" Grid.ColumnSpan="2">
                                                    <Border.BorderBrush>
                                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                            <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                        </LinearGradientBrush>
                                                    </Border.BorderBrush>
                                                </Border>
                                                <ContentControl HorizontalAlignment="Stretch" Margin="6,4" VerticalAlignment="Center" IsTabStop="False" Content="{TemplateBinding Title}" Foreground="#FF042271" FontWeight="Bold"/>
                                                <Button x:Name="CloseButton" Height="14" HorizontalAlignment="Center" Style="{StaticResource CloseButtonStyle}" VerticalAlignment="Center" Width="15" IsTabStop="False" Grid.Column="1"/>
                                            </Grid>
                                        </Border>
                                        <Border Margin="7" Grid.Row="1" Background="{TemplateBinding Background}">
                                            <ContentPresenter x:Name="ContentPresenter" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                        </Border>
                                    </Grid>
                                </Border>
                            </Border>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- DataPager-->
    <Style TargetType="data:DataPager">
        <Setter Property="Background" Value="#FFF2F3F4"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFA3AEB9" Offset="0"/>
                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                    <GradientStop Color="#FF718597" Offset="0.375"/>
                    <GradientStop Color="#FF617584" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="HorizontalContentAlignment" Value="Right"/>
        <Setter Property="NumericButtonStyle">
            <Setter.Value>
                <Style TargetType="ToggleButton">
                    <Setter Property="MinHeight" Value="20"/>
                    <Setter Property="MinWidth" Value="20"/>
                    <Setter Property="HorizontalAlignment" Value="Right"/>
                    <Setter Property="VerticalAlignment" Value="Center"/>
                    <Setter Property="Background" Value="#00000000"/>
                    <Setter Property="BorderThickness" Value="1"/>
                    <Setter Property="Padding" Value="1"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="ToggleButton">
                                <Grid>
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualState x:Name="Normal"/>
                                            <VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="OuterBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFFFFFFF"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFCCD1D6"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="OuterBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFFFFFFF"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFCCD1D6"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                </Storyboard>
                                            </VisualState>
                                        </VisualStateGroup>
                                        <VisualStateGroup x:Name="CheckStates">
                                            <VisualState x:Name="Checked">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="CheckedStateOuterBorder" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Unchecked"/>
                                        </VisualStateGroup>
                                        <VisualStateGroup x:Name="FocusStates">
                                            <VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Unfocused"/>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Border x:Name="CheckedStateOuterBorder" Opacity="0" Background="#7FA9A9A9" BorderBrush="#00FFFFFF" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3"/>
                                    <Border x:Name="OuterBtnBorder" Background="{TemplateBinding Background}" BorderBrush="#00FFFFFF" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3">
                                        <Border x:Name="InnerBtnBorder" BorderBrush="#00CCD1D6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                                            <ContentPresenter x:Name="contentPresenter" HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                        </Border>
                                    </Border>
                                    <Border x:Name="FocusVisualElement" Margin="1" Opacity="0" Background="{TemplateBinding Background}" BorderBrush="#FF6DBDD1" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2"/>
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="data:DataPager">
                    <Grid x:Name="Root" Background="Transparent">
                        <Grid.Resources>
                            <SolidColorBrush x:Key="BackgroundColor" Color="#00000000"/>
                            <SolidColorBrush x:Key="ForegroundColor" Color="#FF000000"/>
                            <SolidColorBrush x:Key="BorderBrushColor" Color="#FFFFFFFF"/>
                            <ControlTemplate x:Key="ButtonTemplate" TargetType="Button">
                                <Grid>
                                    <VisualStateManager.VisualStateGroups>
                                        <VisualStateGroup x:Name="CommonStates">
                                            <VisualState x:Name="Normal"/>
                                            <VisualState x:Name="MouseOver">
                                                <Storyboard>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="OuterBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFFFFFFF"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFCCD1D6"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Pressed">
                                                <Storyboard>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="OuterBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FFFFFFFF"/>
                                                    <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#00FFFFFF"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Disabled">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="path" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                                </Storyboard>
                                            </VisualState>
                                        </VisualStateGroup>
                                        <VisualStateGroup x:Name="FocusStates">
                                            <VisualState x:Name="Focused">
                                                <Storyboard>
                                                    <DoubleAnimation Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                </Storyboard>
                                            </VisualState>
                                            <VisualState x:Name="Unfocused"/>
                                        </VisualStateGroup>
                                    </VisualStateManager.VisualStateGroups>
                                    <Border x:Name="OuterBtnBorder" Background="{TemplateBinding Background}" BorderBrush="#00FFFFFF" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3">
                                        <Border x:Name="InnerBtnBorder" BorderBrush="#00CCD1D6" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                                            <ContentPresenter x:Name="path" Content="{TemplateBinding Content}"/>
                                        </Border>
                                    </Border>
                                    <Border x:Name="FocusVisualElement" Margin="1" Opacity="0" Background="{TemplateBinding Background}" BorderBrush="#FF6DBDD1" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2"/>
                                </Grid>
                            </ControlTemplate>
                            <Style x:Key="PagingTextBoxStyle" TargetType="TextBox">
                                <Setter Property="BorderThickness" Value="1"/>
                                <Setter Property="Background" Value="#FFFFFFFF"/>
                                <Setter Property="Foreground" Value="#FF000000"/>
                                <Setter Property="Padding" Value="2, 2, 2, -1"/>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="TextBox">
                                            <Grid x:Name="RootElement">
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal"/>
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <ColorAnimation Storyboard.TargetName="MouseOverBorder" Storyboard.TargetProperty="(BorderBrush).Color" To="#FF99C1E2"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimation Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="ReadOnly">
                                                            <Storyboard>
                                                                <DoubleAnimation Storyboard.TargetName="ReadOnlyVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                    <VisualStateGroup x:Name="FocusStates">
                                                        <VisualState x:Name="Focused">
                                                            <Storyboard>
                                                                <DoubleAnimation Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Unfocused"/>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Border x:Name="Border" Opacity="1" Background="#66FFFFFF" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="1">
                                                    <Grid>
                                                        <Border x:Name="ReadOnlyVisualElement" Opacity="0" Background="#72F7F7F7"/>
                                                        <Border x:Name="MouseOverBorder" BorderBrush="Transparent" BorderThickness="1">
                                                            <ScrollViewer x:Name="ContentElement" BorderThickness="0" IsTabStop="False" Padding="{TemplateBinding Padding}" Margin="0,-3,0,0" VerticalAlignment="Top"/>
                                                        </Border>
                                                    </Grid>
                                                </Border>
                                                <Border x:Name="DisabledVisualElement" IsHitTestVisible="False" Opacity="0" Background="#A5F7F7F7" BorderBrush="#A5F7F7F7" BorderThickness="{TemplateBinding BorderThickness}"/>
                                                <Border x:Name="FocusVisualElement" Margin="1" IsHitTestVisible="False" Opacity="0" BorderBrush="#FF6DBDD1" BorderThickness="{TemplateBinding BorderThickness}"/>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                            <Style x:Key="PagerButtonStyle" TargetType="Button">
                                <Setter Property="Background" Value="#FF1F3B53"/>
                                <Setter Property="Foreground" Value="#FF000000"/>
                                <Setter Property="Padding" Value="3"/>
                                <Setter Property="BorderThickness" Value="1"/>
                                <Setter Property="BorderBrush">
                                    <Setter.Value>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFA3AEB9" Offset="0"/>
                                            <GradientStop Color="#FF8399A9" Offset="0.375"/>
                                            <GradientStop Color="#FF718597" Offset="0.375"/>
                                            <GradientStop Color="#FF617584" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="Button">
                                            <Grid>
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal"/>
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.8"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.8"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgoundPressed_Highlight" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="Opacity">
                                                                    <SplineDoubleKeyFrame KeyTime="0" Value=".55"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                    <VisualStateGroup x:Name="FocusStates">
                                                        <VisualState x:Name="Focused">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity">
                                                                    <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Unfocused"/>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Border x:Name="Background" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3" Background="White" BorderBrush="#B26593CF">
                                                    <Grid Margin="0" Background="{TemplateBinding Background}">
                                                        <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                                    <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                                                    <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                                                    <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                                                    <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                                                    <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                        </Border>
                                                        <Border x:Name="BackgroundNorm_highlight" Margin="0" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65"/>
                                                        <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                                                    <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                                                    <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgroundOver_Highlight" Margin="0" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                                                    <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgoundPressed_Highlight" Margin="0" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0">
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                    </Grid>
                                                </Border>
                                                <ContentPresenter x:Name="contentPresenter" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                                <Rectangle x:Name="DisabledVisualElement" Fill="#FFFFFFFF" RadiusX="3" RadiusY="3" IsHitTestVisible="false" Opacity="0"/>
                                                <Rectangle x:Name="FocusVisualElement" Stroke="#FF6DBDD1" StrokeThickness="1" RadiusX="2" RadiusY="2" Margin="1" IsHitTestVisible="false" Opacity="0"/>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                        </Grid.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentPagePrefixTextBlock" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="CurrentPageSuffixTextBlock" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="MoveStates">
                                <VisualState x:Name="MoveEnabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MoveDisabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="MoveFirstStates">
                                <VisualState x:Name="MoveFirstEnabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FirstPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MoveFirstDisabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="FirstPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="MovePreviousStates">
                                <VisualState x:Name="MovePreviousEnabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="PreviousPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MovePreviousDisabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="PreviousPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="MoveNextStates">
                                <VisualState x:Name="MoveNextEnabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="NextPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MoveNextDisabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="NextPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="MoveLastStates">
                                <VisualState x:Name="MoveLastEnabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="LastPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="True"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="MoveLastDisabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="LastPageButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="DisplayModeStates">
                                <VisualState x:Name="FirstLastNumeric">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="NextPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PreviousPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PageDisplay" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="FirstLastPreviousNext">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="NumericButtonPanel" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="FirstLastPreviousNextNumeric">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PageDisplay" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Numeric">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="FirstPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="LastPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="NextPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PreviousPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PageDisplay" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Separator1" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Separator2" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="PreviousNext">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="FirstPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="LastPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="NumericButtonPanel" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="PreviousNextNumeric">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="FirstPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="LastPageButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="CurrentPageTextBox" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PageDisplay" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border MinHeight="24" VerticalAlignment="Bottom" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2" Padding="{TemplateBinding Padding}">
                            <StackPanel HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="Stretch" Orientation="Horizontal" Margin="0,0,10,0">
                                <Button x:Name="FirstPageButton" Background="{StaticResource BackgroundColor}" BorderBrush="{StaticResource BorderBrushColor}" BorderThickness="1" Foreground="{StaticResource ForegroundColor}" Padding="1" Height="20" HorizontalAlignment="Right" VerticalAlignment="Center" Width="20" Style="{StaticResource PagerButtonStyle}">
                                    <Grid Height="9" Width="8">
                                        <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Right" Width="5" Data="M0,1 L1,0 L1,2 Z"/>
                                        <Rectangle Fill="{TemplateBinding Foreground}" HorizontalAlignment="Left" Width="2"/>
                                    </Grid>
                                </Button>
                                <Button x:Name="PreviousPageButton" Background="{StaticResource BackgroundColor}" BorderBrush="{StaticResource BorderBrushColor}" BorderThickness="1" Foreground="{StaticResource ForegroundColor}" Padding="1" Height="20" HorizontalAlignment="Right" VerticalAlignment="Center" Width="20" Style="{StaticResource PagerButtonStyle}">
                                    <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Center" Width="5" Data="M0,1 L1,0 L1,2 Z"/>
                                </Button>
                                <Border x:Name="Separator1" Margin="0,3,0,3" Width="1" Background="#FFCCD1D6" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="0"/>
                                <StackPanel x:Name="NumericButtonPanel" Margin="1" Orientation="Horizontal"/>
                                <StackPanel x:Name="PageDisplay" Orientation="Horizontal">
                                    <TextBlock x:Name="CurrentPagePrefixTextBlock" Margin="4,0,0,0" VerticalAlignment="Center" Width="Auto" Foreground="{TemplateBinding Foreground}"/>
                                    <TextBox x:Name="CurrentPageTextBox" BorderBrush="{TemplateBinding BorderBrush}" Foreground="{TemplateBinding Foreground}" Height="Auto" Margin="4,2,4,2" VerticalAlignment="Center" Width="40" TextWrapping="Wrap"/>
                                    <TextBlock x:Name="CurrentPageSuffixTextBlock" Margin="0,0,4,0" VerticalAlignment="Center" Width="Auto" Foreground="{TemplateBinding Foreground}"/>
                                </StackPanel>
                                <Border x:Name="Separator2" Margin="0,3,0,3" Width="1" Background="#FFCCD1D6" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="0"/>
                                <Button x:Name="NextPageButton" Background="{StaticResource BackgroundColor}" BorderBrush="{StaticResource BorderBrushColor}" BorderThickness="1" Foreground="{StaticResource ForegroundColor}" Padding="1" Height="20" HorizontalAlignment="Right" VerticalAlignment="Center" Width="20" Style="{StaticResource PagerButtonStyle}">
                                    <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Center" Width="5" Data="M0,0 L1,1 L0,2 Z"/>
                                </Button>
                                <Button x:Name="LastPageButton" Background="{StaticResource BackgroundColor}" BorderBrush="{StaticResource BorderBrushColor}" BorderThickness="1" Foreground="{StaticResource ForegroundColor}" Padding="1" Height="20" HorizontalAlignment="Right" VerticalAlignment="Center" Width="20" Style="{StaticResource PagerButtonStyle}">
                                    <Grid Height="9" Width="8">
                                        <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Left" Width="5" Data="M0,0 L1,1 L0,2 Z"/>
                                        <Rectangle Fill="{TemplateBinding Foreground}" HorizontalAlignment="Right" Width="2"/>
                                    </Grid>
                                </Button>
                            </StackPanel>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--DataForm-->
    <Style TargetType="dataForm:DataForm">
        <Setter Property="AutoCommit" Value="True"/>
        <Setter Property="AutoGenerateFields" Value="True"/>
        <Setter Property="Background">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFF3F7FA" Offset="0"/>
                    <GradientStop Color="#FFFFFFFF" Offset="0.1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="BorderBrush">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                    <GradientStop Color="#FFA3AEB9" Offset="0"/>
                    <GradientStop Color="#FF8399A9" Offset="0.375"/>
                    <GradientStop Color="#FF718597" Offset="0.375"/>
                    <GradientStop Color="#FF617584" Offset="1"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="DescriptionViewerPosition" Value="Auto"/>
        <Setter Property="LabelPosition" Value="Auto"/>
        <Setter Property="HeaderVisibility" Value="Visible"/>
        <Setter Property="Padding" Value="5"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="dataForm:DataForm">
                    <Grid dataForm:DataField.IsFieldGroup="True">
                        <Grid.Resources>
                            <Style x:Key="ButtonGeneric" TargetType="Button">
                                <Setter Property="Background" Value="#00000000"/>
                                <Setter Property="Foreground" Value="#FF000000"/>
                                <Setter Property="BorderBrush" Value="#FFFFFFFF"/>
                                <Setter Property="BorderThickness" Value="1"/>
                                <Setter Property="Padding" Value="1"/>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="Button">
                                            <Grid>
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal"/>
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="OuterBtnBorder" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#FFFFFFFF"/>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#7FA9A9A9"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" To="#7FA9A9A9"/>
                                                                <ColorAnimation Duration="0" Storyboard.TargetName="InnerBtnBorder" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" To="#7FA9A9A9"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="Opacity" To="0.3"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                    <VisualStateGroup x:Name="FocusStates">
                                                        <VisualState x:Name="Focused">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0" Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity" To="1"/>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Unfocused"/>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Border x:Name="OuterBtnBorder" Background="{TemplateBinding Background}" BorderBrush="#00FFFFFF" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3">
                                                    <Border x:Name="InnerBtnBorder" Background="#00A9A9A9" BorderBrush="#00A9A9A9" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                                                        <ContentPresenter x:Name="contentPresenter" Height="Auto" HorizontalAlignment="Center" VerticalAlignment="Center" Width="Auto" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                                    </Border>
                                                </Border>
                                                <Border x:Name="FocusVisualElement" Margin="1" Opacity="0" Background="{TemplateBinding Background}" BorderBrush="#FF6DBDD1" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2"/>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                            <Style x:Key="CustomScrollViewerStyle" TargetType="ScrollViewer">
                                <Setter Property="HorizontalContentAlignment" Value="Left"/>
                                <Setter Property="VerticalContentAlignment" Value="Top"/>
                                <Setter Property="BorderThickness" Value="0,1"/>
                                <Setter Property="BorderBrush">
                                    <Setter.Value>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFA3AEB9" Offset="0"/>
                                            <GradientStop Color="#FF8399A9" Offset="0.375"/>
                                            <GradientStop Color="#FF718597" Offset="0.375"/>
                                            <GradientStop Color="#FF617584" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="ScrollViewer">
                                            <Grid>
                                                <Border Margin="0,-1" Opacity="0.2" Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
                                                    <Border.OpacityMask>
                                                        <LinearGradientBrush EndPoint="1.07,0.5" StartPoint="-0.07,0.5">
                                                            <GradientStop Color="#FF000000"/>
                                                            <GradientStop Color="#7FFFFFFF" Offset="0.5"/>
                                                            <GradientStop Color="#FF000000" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Border.OpacityMask>
                                                </Border>
                                                <Grid Background="{TemplateBinding Background}">
                                                    <Grid.ColumnDefinitions>
                                                        <ColumnDefinition Width="*"/>
                                                        <ColumnDefinition Width="Auto"/>
                                                    </Grid.ColumnDefinitions>
                                                    <Grid.RowDefinitions>
                                                        <RowDefinition Height="*"/>
                                                        <RowDefinition Height="Auto"/>
                                                    </Grid.RowDefinitions>
                                                    <ScrollContentPresenter x:Name="ScrollContentPresenter" Cursor="{TemplateBinding Cursor}" Margin="{TemplateBinding Padding}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                                    <Rectangle Fill="#FFE9EEF4" Grid.Column="1" Grid.Row="1"/>
                                                    <ScrollBar x:Name="VerticalScrollBar" Margin="0,-1" Width="18" Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}" IsTabStop="False" Grid.Column="1" Grid.Row="0" Maximum="{TemplateBinding ScrollableHeight}" Minimum="0" Value="{TemplateBinding VerticalOffset}" Orientation="Vertical" ViewportSize="{TemplateBinding ViewportHeight}"/>
                                                    <ScrollBar x:Name="HorizontalScrollBar" Height="18" Margin="-1,0,-1,-1" Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}" IsTabStop="False" Grid.Column="0" Grid.Row="1" Maximum="{TemplateBinding ScrollableWidth}" Minimum="0" Value="{TemplateBinding HorizontalOffset}" Orientation="Horizontal" ViewportSize="{TemplateBinding ViewportWidth}"/>
                                                </Grid>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                            <Style x:Key="DataFormButtonStyle" TargetType="Button">
                                <Setter Property="Background" Value="#FF1F3B53"/>
                                <Setter Property="Foreground" Value="#FF000000"/>
                                <Setter Property="Padding" Value="3"/>
                                <Setter Property="BorderThickness" Value="1"/>
                                <Setter Property="BorderBrush">
                                    <Setter.Value>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFA3AEB9" Offset="0"/>
                                            <GradientStop Color="#FF8399A9" Offset="0.375"/>
                                            <GradientStop Color="#FF718597" Offset="0.375"/>
                                            <GradientStop Color="#FF617584" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Setter.Value>
                                </Setter>
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="Button">
                                            <Grid>
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal"/>
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundOver_Highlight" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgroundPressed" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BackgoundPressed_Highlight_Copy" Storyboard.TargetProperty="(UIElement.Opacity)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.85"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="Opacity">
                                                                    <SplineDoubleKeyFrame KeyTime="0" Value="0.75"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(Shape.StrokeThickness)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.967"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.X)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="-0.031"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.884"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="DisabledVisualElement" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
                                                                    <EasingDoubleKeyFrame KeyTime="00:00:00" Value="0.094"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                    <VisualStateGroup x:Name="FocusStates">
                                                        <VisualState x:Name="Focused">
                                                            <Storyboard>
                                                                <DoubleAnimationUsingKeyFrames Storyboard.TargetName="FocusVisualElement" Storyboard.TargetProperty="Opacity">
                                                                    <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
                                                                </DoubleAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Unfocused"/>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Border x:Name="Background" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="3" BorderBrush="#B26593CF">
                                                    <Grid Margin="1">
                                                        <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="2.5" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                                    <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                                                    <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                                                    <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                                                    <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                                                    <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                        </Border>
                                                        <Border x:Name="BackgroundNorm_highlight" Margin="0" BorderBrush="#B26593CF" BorderThickness="1" CornerRadius="2.5" Opacity="0.55"/>
                                                        <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="2.5" Opacity="0" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                                                    <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                                                    <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                                                    <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                                                    <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                                                    <GradientStop Color="#FFFFF48B" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                                                    <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                                                    <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgroundOver_Highlight" Margin="0" BorderThickness="1,0,1,1" CornerRadius="2.5" Opacity="0">
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                                                    <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="2.5" Opacity="0" Margin="0">
                                                            <Border.Background>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                                    <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                                                    <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                                                    <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                                                    <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                                                    <GradientStop Color="#FFFFC472" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.Background>
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FF8E8165" Offset="0"/>
                                                                    <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                        <Border x:Name="BackgoundPressed_Highlight_Copy" Margin="0" BorderThickness="1,0,1,1" CornerRadius="2.5" Opacity="0">
                                                            <Border.BorderBrush>
                                                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                                                    <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                                                    <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                                                </LinearGradientBrush>
                                                            </Border.BorderBrush>
                                                        </Border>
                                                    </Grid>
                                                </Border>
                                                <ContentPresenter x:Name="contentPresenter" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
                                                <Rectangle x:Name="DisabledVisualElement" Fill="#FFFFFFFF" RadiusX="2.5" RadiusY="2.5" IsHitTestVisible="false" Opacity="0" StrokeThickness="0" RenderTransformOrigin="0.5,0.5">
                                                    <Rectangle.RenderTransform>
                                                        <TransformGroup>
                                                            <ScaleTransform/>
                                                            <SkewTransform/>
                                                            <RotateTransform/>
                                                            <TranslateTransform/>
                                                        </TransformGroup>
                                                    </Rectangle.RenderTransform>
                                                </Rectangle>
                                                <Rectangle x:Name="FocusVisualElement" Stroke="#FF6DBDD1" StrokeThickness="1" RadiusX="2" RadiusY="2" Margin="1" IsHitTestVisible="false" Opacity="0"/>
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                        </Grid.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="DisabledVisual" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ModeStates">
                                <VisualState x:Name="ReadOnly"/>
                                <VisualState x:Name="Empty">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="IsHitTestVisible">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="False"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Opacity" To="0"/>
                                    </Storyboard>
                                </VisualState>
                                <VisualState x:Name="Edit">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="EditButton" Storyboard.TargetProperty="IsEnabled">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="false"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CommitButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetName="CancelButton" Storyboard.TargetProperty="Visibility">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ValidationStates">
                                <VisualState x:Name="Valid"/>
                                <VisualState x:Name="Invalid"/>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="CommittedStates">
                                <VisualState x:Name="Committed"/>
                                <VisualState x:Name="Uncommitted">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="ChangeIndicator" Storyboard.TargetProperty="Opacity" To="0.9"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="ScopeStates">
                                <VisualState x:Name="Entity"/>
                                <VisualState x:Name="Collection"/>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border x:Name="DataFormBorder" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="2">
                            <Grid>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition/>
                                    <RowDefinition Height="Auto"/>
                                    <RowDefinition Height="Auto"/>
                                </Grid.RowDefinitions>
                                <Border x:Name="BackgroundNorm" BorderThickness="1" CornerRadius="1.75" Margin="0" Grid.RowSpan="2" Opacity="0.55">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,0" StartPoint="0.5,1">
                                            <GradientStop Color="#FF84B2D4"/>
                                            <GradientStop Color="#FFADC7DE" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                            <GradientStop Color="#FF8AAEDA" Offset="0.521"/>
                                            <GradientStop Color="#FFC6D6EC" Offset="0.194"/>
                                            <GradientStop Color="#FFB4C9E5" Offset="0.811"/>
                                            <GradientStop Color="#FFB7C8E0" Offset="0.507"/>
                                            <GradientStop Color="#FFD1DEF0" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                                <Border x:Name="BackgroundNorm_highlight" Margin="0,1,0,0" BorderBrush="#FFFFFFFF" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0.65" Grid.RowSpan="2"/>
                                <Border x:Name="BackgroundOver" BorderThickness="1" CornerRadius="1.75" Opacity="0" Margin="0" Grid.RowSpan="2">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0"/>
                                            <GradientStop Color="#FFFEF3B5" Offset="0.318"/>
                                            <GradientStop Color="#FFFFEB70" Offset="0.488"/>
                                            <GradientStop Color="#FFFFD02E" Offset="0.502"/>
                                            <GradientStop Color="#FFFFD932" Offset="0.834"/>
                                            <GradientStop Color="#FFFFF48B" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFEEE8CF" Offset="0"/>
                                            <GradientStop Color="#FFC4AF8C" Offset="0.536"/>
                                            <GradientStop Color="#FFDCD1BF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgroundOver_Highlight" Margin="0,1,0,0" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0" Grid.RowSpan="2">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFB" Offset="0"/>
                                            <GradientStop Color="#FFFEF3B5" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgroundPressed" BorderThickness="1" CornerRadius="1.75" Opacity="0" Margin="0" Grid.RowSpan="2">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                            <GradientStop Color="#FFFDCE9D" Offset="0.046"/>
                                            <GradientStop Color="#FFFFA35B" Offset="0.452"/>
                                            <GradientStop Color="#FFFF8A2C" Offset="0.461"/>
                                            <GradientStop Color="#FFFF9F30" Offset="0.724"/>
                                            <GradientStop Color="#FFFFC472" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FF8E8165" Offset="0"/>
                                            <GradientStop Color="#FFC3BCAE" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Border x:Name="BackgoundPressed_Highlight_Copy" Margin="0,1,0,0" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0" Grid.RowSpan="2">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                                <Grid MinHeight="27" Visibility="{TemplateBinding HeaderVisibility}">
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition/>
                                        <ColumnDefinition Width="Auto"/>
                                        <ColumnDefinition Width="8"/>
                                    </Grid.ColumnDefinitions>
                                    <StackPanel Orientation="Horizontal">
                                        <ContentControl x:Name="HeaderElement" Margin="10,0,0,0" VerticalAlignment="Center" FontWeight="Bold" Content="{TemplateBinding Header}" ContentTemplate="{TemplateBinding HeaderTemplate}" Foreground="#FF042271"/>
                                        <TextBlock x:Name="ChangeIndicator" Margin="3,-2,8,2" VerticalAlignment="Center" Opacity="0" FontWeight="Bold" Text="*" Foreground="#FF042271"/>
                                    </StackPanel>
                                    <StackPanel Margin="0,3,0,2" Grid.Column="2" Orientation="Horizontal">
                                        <Button x:Name="FirstItemButton" Style="{StaticResource DataFormButtonStyle}" Background="{x:Null}" BorderBrush="{x:Null}" BorderThickness="0">
                                            <Grid Height="9" Margin="6,5,5,5" Width="8" Opacity="1">
                                                <Grid.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.6,1" StartPoint="0.4,0">
                                                        <GradientStop Color="#7FFFFFFF" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Grid.OpacityMask>
                                                <Grid.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" Opacity="1" ShadowDepth="0"/>
                                                </Grid.Effect>
                                                <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Right" Margin="0" Width="5" Opacity="0.85" Data="M1,0 L1,2 L0,1 Z"/>
                                                <Rectangle Fill="{TemplateBinding Foreground}" HorizontalAlignment="Left" Width="2" Opacity="0.85"/>
                                            </Grid>
                                        </Button>
                                        <Button x:Name="PreviousItemButton" Style="{StaticResource DataFormButtonStyle}" Background="{x:Null}" BorderBrush="{x:Null}" BorderThickness="0">
                                            <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" Margin="6,5,8,5" Width="5" Opacity="0.85" Data="M1,0 L1,2 L0,1 Z">
                                                <Path.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.6,1" StartPoint="0.4,0">
                                                        <GradientStop Color="#7F000000" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Path.OpacityMask>
                                                <Path.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" ShadowDepth="0"/>
                                                </Path.Effect>
                                            </Path>
                                        </Button>
                                        <Button x:Name="NextItemButton" Style="{StaticResource DataFormButtonStyle}" Background="{x:Null}" BorderBrush="{x:Null}" BorderThickness="0">
                                            <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" Margin="8,5,6,5" Width="5" Opacity="0.85" Data="M0,0 L1,1 L0,2 Z">
                                                <Path.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.6,1" StartPoint="0.4,0">
                                                        <GradientStop Color="#7F000000" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Path.OpacityMask>
                                                <Path.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" ShadowDepth="0"/>
                                                </Path.Effect>
                                            </Path>
                                        </Button>
                                        <Button x:Name="LastItemButton" Style="{StaticResource DataFormButtonStyle}" Background="{x:Null}" BorderBrush="{x:Null}" BorderThickness="0">
                                            <Grid Height="9" Margin="6,5,5,5" Width="8" Opacity="1">
                                                <Grid.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.6,1" StartPoint="0.4,0">
                                                        <GradientStop Color="#7F000000" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Grid.OpacityMask>
                                                <Grid.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" ShadowDepth="0"/>
                                                </Grid.Effect>
                                                <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Left" Width="5" Opacity="0.85" Data="M0,0 L1,1 L0,2 Z"/>
                                                <Rectangle Fill="{TemplateBinding Foreground}" HorizontalAlignment="Right" Width="2" Opacity="0.85"/>
                                            </Grid>
                                        </Button>
                                        <Border x:Name="ButtonSeparator" Margin="2,4,2,4" Width="3" Opacity="0.2" Background="{TemplateBinding BorderBrush}" BorderBrush="#59FFFFFF" BorderThickness="1,0,1,0"/>
                                        <Button x:Name="EditButton" ToolTipService.ToolTip="Edit" Style="{StaticResource DataFormButtonStyle}" BorderBrush="{x:Null}" Background="{x:Null}" BorderThickness="0">
                                            <Button.OpacityMask>
                                                <LinearGradientBrush EndPoint="0.57,0.76" StartPoint="0.42,0.01">
                                                    <GradientStop Color="#7F000000" Offset="0"/>
                                                    <GradientStop Color="#BF000000" Offset="0.442"/>
                                                    <GradientStop Color="#FF000000" Offset="1"/>
                                                </LinearGradientBrush>
                                            </Button.OpacityMask>
                                            <Grid Height="19" HorizontalAlignment="Center" VerticalAlignment="Center" Width="19">
                                                <Canvas HorizontalAlignment="Stretch" Margin="2,2,0,0" VerticalAlignment="Stretch">
                                                    <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="10.5" Width="10.56" Canvas.Left="2.53" Canvas.Top="3.01" Data="F1 M 2.53,9.96L 4.96,11.1L 6.08,13.50L 13.09,6.50L 9.6,3L 2.53,9.96 Z ">
                                                        <Path.OpacityMask>
                                                            <LinearGradientBrush EndPoint="0.76,0.77" StartPoint="0.21,0.18">
                                                                <GradientStop Color="#7F000000" Offset="0"/>
                                                                <GradientStop Color="#59000000" Offset="0.106"/>
                                                                <GradientStop Color="#3F000000" Offset="0.387"/>
                                                                <GradientStop Color="#99000000" Offset="0.703"/>
                                                                <GradientStop Color="#CC000000" Offset="1"/>
                                                            </LinearGradientBrush>
                                                        </Path.OpacityMask>
                                                    </Path>
                                                    <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="6.74" Width="6.81" Canvas.Left="7.47" Canvas.Top="1.89" Data="M1.41,1.83 L0.71,2.54 L4.20,6.03 L4.91,5.33 z M3.24,0 L6.81,3.42 L3.5,6.74 L0,3.24 z"/>
                                                    <Path Stretch="Fill" Stroke="{TemplateBinding Foreground}" StrokeLineJoin="Round" Height="12.5" Width="12.43" Canvas.Left="2.03" Canvas.Top="1.50" Data="F1 M 13.77,4.22L 11.73,2.18C 11.12,1.78 10.46,2.15 10,2.5L 3.04,9.45C 2.65,9.86 2.53,10.47 2.53,10.73L 2.53,13.5L 5.32,13.5C 5.57,13.5 6.33,13.36 6.64,12.93L 13.54,6.03C 13.86,5.72 14.17,4.74 13.77,4.22 Z"/>
                                                    <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="2.29" Width="2.33" Canvas.Left="2.58" Canvas.Top="11.18" Data="F1 M 2.033,11.71L 4.33,14L 2.62,14C 2.17,13.93 2.09,13.79 2,13.31L 2.03,11.71 Z"/>
                                                </Canvas>
                                            </Grid>
                                        </Button>
                                        <Button x:Name="NewItemButton" ToolTipService.ToolTip="Add" Style="{StaticResource DataFormButtonStyle}" Background="{x:Null}" BorderBrush="{x:Null}" BorderThickness="0">
                                            <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Center" Margin="5" VerticalAlignment="Center" Width="9" Opacity="0.85" RenderTransformOrigin="0.5,0.5" Data="F1 M18.41,61.67 L19.56,60.52 L21.92,62.88 L24.22,60.57 L25.36,61.72 L23.06,64.03 L25.43,66.4 L24.22,67.60 L21.87,65.25 L19.56,67.56 L18.41,66.41 L20.73,64.08 L18.41,61.67 z">
                                                <Path.RenderTransform>
                                                    <TransformGroup>
                                                        <ScaleTransform/>
                                                        <SkewTransform/>
                                                        <RotateTransform Angle="45"/>
                                                        <TranslateTransform X="0.18" Y="-0.07"/>
                                                    </TransformGroup>
                                                </Path.RenderTransform>
                                                <Path.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" ShadowDepth="0"/>
                                                </Path.Effect>
                                                <Path.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.35,0.5" StartPoint="-0.27,0.05">
                                                        <GradientStop Color="#7F000000" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Path.OpacityMask>
                                            </Path>
                                        </Button>
                                        <Button x:Name="DeleteItemButton" ToolTipService.ToolTip="Delete" Style="{StaticResource DataFormButtonStyle}" BorderBrush="{x:Null}" Background="{x:Null}" BorderThickness="0">
                                            <Path Fill="{TemplateBinding Foreground}" Stretch="Fill" Height="9" HorizontalAlignment="Center" Margin="5,5,5,5" VerticalAlignment="Center" Width="9" Opacity="0.85" RenderTransformOrigin="0.5,0.5" Data="F1 M24.32,60.48 L25.60,61.76 L19.65,67.75 L18.37,66.46 z">
                                                <Path.RenderTransform>
                                                    <TransformGroup>
                                                        <RotateTransform Angle="45"/>
                                                        <TranslateTransform X="0.06" Y="-0.01"/>
                                                    </TransformGroup>
                                                </Path.RenderTransform>
                                                <Path.Effect>
                                                    <DropShadowEffect BlurRadius="8" Color="#FFFFFFFF" Direction="100" ShadowDepth="0"/>
                                                </Path.Effect>
                                                <Path.OpacityMask>
                                                    <LinearGradientBrush EndPoint="0.74,0.66" StartPoint="-0.44,-0.11">
                                                        <GradientStop Color="#7F000000" Offset="0"/>
                                                        <GradientStop Color="#BF000000" Offset="0.25"/>
                                                        <GradientStop Color="#FF000000" Offset="1"/>
                                                    </LinearGradientBrush>
                                                </Path.OpacityMask>
                                            </Path>
                                        </Button>
                                    </StackPanel>
                                </Grid>
                                <ScrollViewer Style="{StaticResource CustomScrollViewerStyle}" Background="{x:Null}" IsTabStop="False" Padding="{TemplateBinding Padding}" Grid.Row="1" VerticalScrollBarVisibility="Auto">
                                    <ContentPresenter x:Name="ContentPresenter" Margin="7,7,1,7"/>
                                </ScrollViewer>
                                <dataInput:ValidationSummary x:Name="ValidationSummary" MaxHeight="100" BorderThickness="0" Grid.Row="2"/>
                                <StackPanel HorizontalAlignment="Right" Grid.Row="3" Orientation="Horizontal">
                                    <Button x:Name="CommitButton" Margin="0,5,8,5" MinHeight="17" MinWidth="71" Visibility="Collapsed" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Content="OK" Style="{StaticResource DataFormButtonStyle}"/>
                                    <Button x:Name="CancelButton" Margin="0,5,8,5" MinHeight="17" MinWidth="71" Visibility="Collapsed" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Content="Cancel" Style="{StaticResource DataFormButtonStyle}"/>
                                </StackPanel>
                                <Border x:Name="BackgoundPressed_Highlight" Margin="1,1,0,-7" BorderThickness="1,0,1,1" CornerRadius="1" Opacity="0" HorizontalAlignment="Left" Width="123" Grid.RowSpan="3" Grid.Row="1">
                                    <Border.BorderBrush>
                                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                            <GradientStop Color="#FFFFFFFF" Offset="0.665"/>
                                            <GradientStop Color="#FFC3BCAE" Offset="0"/>
                                        </LinearGradientBrush>
                                    </Border.BorderBrush>
                                </Border>
                            </Grid>
                        </Border>
                        <Border x:Name="DisabledVisual" IsHitTestVisible="False" Opacity="0" Background="#8CFFFFFF" CornerRadius="2"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--GridSplitter-->
    <Style TargetType="controls:GridSplitter">
        <Setter Property="Background" Value="Transparent"/>
        <Setter Property="IsTabStop" Value="true"/>
        <Setter Property="HorizontalAlignment" Value="Right"/>
        <Setter Property="PreviewStyle">
            <Setter.Value>
                <Style TargetType="Control">
                    <Setter Property="Background" Value="#FF868686"/>
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="Control">
                                <Grid x:Name="Root" Opacity=".5">
                                    <Rectangle Fill="{TemplateBinding Background}"/>
                                    <Grid x:Name="HorizontalTemplate" Height="6"/>
                                    <Grid x:Name="VerticalTemplate" Width="6" Visibility="Collapsed"/>
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:GridSplitter">
                    <Grid x:Name="Root" IsHitTestVisible="{TemplateBinding IsEnabled}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="MouseOver"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="Root" Storyboard.TargetProperty="Opacity" To="0.5"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0"/>
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Unfocused"/>
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0" Storyboard.TargetName="FocusVisual" Storyboard.TargetProperty="Opacity" To="1"/>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Rectangle StrokeThickness="0" Fill="{StaticResource ControlBackgroundBrush}"/>
                        <Grid x:Name="HorizontalTemplate" Height="10">
                            <StackPanel Height="6" VerticalAlignment="Center">
                                <Rectangle Fill="#FF868686" StrokeThickness="0" Height="1" Margin="1" Width="10"/>
                                <Rectangle Fill="#FF868686" StrokeThickness="0" Height="1" Margin="1" Width="10"/>
                            </StackPanel>
                        </Grid>
                        <Grid x:Name="VerticalTemplate" Width="10" Visibility="Collapsed">
                            <StackPanel VerticalAlignment="Center" Width="6" Orientation="Horizontal">
                                <Rectangle Fill="#FF868686" StrokeThickness="0" Height="10" Margin="1" Width="1"/>
                                <Rectangle Fill="#FF868686" StrokeThickness="0" Height="10" Margin="1" Width="1"/>
                            </StackPanel>
                        </Grid>
                        <Rectangle x:Name="FocusVisual" StrokeThickness="1" IsHitTestVisible="false" Opacity="0" Stroke="{StaticResource GridBorder}" Margin="-1"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- DomainUpDown -->
    <Style TargetType="inputToolkit:DomainUpDown">
        <Setter Property="Padding" Value="3,0" />
        <Setter Property="Foreground" Value="{StaticResource TextColor}" />
        <Setter Property="Background" Value="{StaticResource ControlBackgroundBrush}" />
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}" />
        <Setter Property="BorderThickness" Value="2" />
        <Setter Property="IsEnabled" Value="True" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="inputToolkit:DomainUpDown">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualStateGroup.Transitions>
                                    <vsm:VisualTransition GeneratedDuration="0" />
                                </vsm:VisualStateGroup.Transitions>
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="Disabled" />
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="00:00:00.001" Storyboard.TargetName="HasFocus" Storyboard.TargetProperty="(UIElement.Visibility)">
                                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid >
                            <ContentControl Padding="0,0,20,0"
                                    x:Name="Visualization"
                                    Margin="0" 
                                    Opacity="1"
                                    IsTabStop="False"
                                    IsHitTestVisible="False"
                                    HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                    VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                    Content="{TemplateBinding Value}"
                                    ContentTemplate="{TemplateBinding ItemTemplate}"
                                    FontFamily="{TemplateBinding FontFamily}"
                                    FontSize="{TemplateBinding FontSize}"
                                    FontStretch="{TemplateBinding FontStretch}"
                                    Foreground="{TemplateBinding Foreground}" />

                            <TextBox MinWidth="20" Padding="0,0,20,-3" x:Name="Text" Text="{TemplateBinding Value}" IsEnabled="True" AcceptsReturn="False" FontFamily="{TemplateBinding FontFamily}" FontSize="{TemplateBinding FontSize}" FontStretch="{TemplateBinding FontStretch}" FontStyle="{TemplateBinding FontStyle}" FontWeight="{TemplateBinding FontWeight}" TextAlignment="Right" TextWrapping="NoWrap" Foreground="{TemplateBinding Foreground}" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" />
                        </Grid>
                        <inputToolkit:ButtonSpinner x:Name="Spinner" IsEnabled="True" HorizontalAlignment="Right" Width="18" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
                            <Border CornerRadius="0,1,1,0" Background="{TemplateBinding BorderBrush}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />
                        </inputToolkit:ButtonSpinner>
                        <Border x:Name="HasFocus" CornerRadius="1" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1" Margin="-3" Visibility="Collapsed">
                            <Border.OpacityMask>
                                <LinearGradientBrush EndPoint="0,.5" StartPoint="1,.5">
                                    <GradientStop Color="#99000000" Offset="0" />
                                    <GradientStop Color="#33FFFFFF" Offset=".5" />
                                    <GradientStop Color="#99000000" Offset="1" />
                                </LinearGradientBrush>
                            </Border.OpacityMask>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>
